In a post that already exists, implementation-of-monotone-cubic-interpolation, there is a good method for fitting data which necessarily includes all of the given points. But, what if I need to correct for some noise in a data set, and still preserve monotonicity? Is anyone familiar with a method of fitting data that provides a monotonic function that passes through the middle of a set of points, rather than each point individually?

In this case, the data points may not be monotonic to begin with, but because of knowledge of the system I know that a model of the data would have to increase continuously.

(Ultimately, I need to take numerical derivatives of some experimental data sets. The data are spaced far enough apart that it is necessary to interpolate points, or the derivative will have too large of delta x to be useful.)

  • $\begingroup$ You can use least squares with an additional constraint. $\endgroup$ – AnilB Jun 4 '13 at 15:41
  • $\begingroup$ I didn't do a good job of specifying - The model that I am referring to is conceptual; there is no specific function to model the data. In some cases, a good fit can be made with a Stineman interpolation that has been weighted by some percentage of the data - but, that implementation is in a commercial software which cannot be automated for a large number of data sets. I have been unsuccessful in attempts to replicate that. $\endgroup$ – repurposer Jun 4 '13 at 15:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.