paucablop / chemotools

Integrate your chemometric tools with the scikit-learn API πŸ§ͺ πŸ€–
https://paucablop.github.io/chemotools/
MIT License
45 stars 6 forks source link

Enable automated window size determination of Savitzky-Golay and Mean filter (maybe also Median filter) #125

Open MothNik opened 3 months ago

MothNik commented 3 months ago

πŸšΆβž‘οΈπŸƒ Proposed Enhancement

Today, I answered this StackExchange Question on the Savitzky-Golay filter and thereby I figured out that the automated selection of the Savitzky-Golay (and thus the mean filter because it is the Savitzky-Golay filter with polynomial degree 0 😱) is easily possible via Cross Validation. After the WhittakerSmooth might get a facelift (#120) with that enables automated smoothing, I think this is a natural way to proceed. If we trick a bit, actually also the median filter can get this update, but the numerics might be a bit more involved.

MothNik commented 3 months ago

Basically, this would also allow for outlier detection in a next step.