I want to use Savitzky-Golay (savgol) filter to my time series MODIS dataset to remove noises (i.e., cloud pixels, etc.) in my data. MODIS have quality flags that indicates the reliability of each pixel values or if the pixel is possibly affected by clouds. So I would like to incorporate these quality flags in my filter by putting less weight or ignoring those pixel values and let savgol filter predict the optimal pixel value. I am testing np.NaN/np.nan/isnull but it seems that it removes the element in the array, and consequently savgol filter also skip those values. I would like my resulting data to be like in the attached figure.
(https://matinbrandt.wordpress.com/2...e-series-using-a-savitzky-golay-filter-and-r/)
أكثر...

أكثر...