What is disclosed is a system and method for processing a video for respiratory function analysis. In one embodiment, a video is received of a region of the subjects body where a time-varying signal corresponding to the subjects respiration can be registered by the video camera. Pixels in a first batch of frames are processed to obtain a time-series signal which is filtered using a band-pass filter with a low and high cutoff frequency fL and fH, where fL and fH are a function of the subjects tidal breathing. The filtered time-series signal is analyzed to identify a next low and high cutoff frequency f′L and F′H, where fL