Click or drag to resize

PeakFinderSavitzkyGolay(DoubleVector, Int32, Int32) Constructor

An instance of a Savitkzy-Golay peak finder. The width of the filter must be less than the length of the data, and the polynomial degree must be less than the filter width.

Namespace: CenterSpace.NMath.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
public PeakFinderSavitzkyGolay(
	DoubleVector inputdata,
	int width,
	int polynomialdegree
)

Parameters

inputdata  DoubleVector
Input data
width  Int32
Width of peak finder. Note that all even widths are internally increased by one to make them odd as required by the underlying Savitkzy-Golay filter. Odd widths are used as given.
polynomialdegree  Int32
Degree of polynomial to use for fitting
Exceptions
ExceptionCondition
InvalidArgumentExceptionThe filter width must be less than the data length.
InvalidArgumentExceptionThe polynomial degree must be 2 or greater.
InvalidArgumentExceptionInput data cannot be null.
Remarks
Because the width of the underlying Savitkzy-Golay filter must always be odd, the width of the filter is calculated with the formula: Savitkzy-Golay Filter Width = 2.0 * Math.Floor(width/2.0) + 1.
See Also