ExtendDatacubeByDerivative

Declaration: ExtendDatacubeByDerivative(FirstLayer, LastLayer, Order, WindowSize, Group: integer; FeedBack: boolean): integer;
Extends the data cube by (LastLayer-FirstLayer+1) layers and fills the new layers with the smoothed derivative of the spectrum between FirstLayer and LastLayer. The parameter Order determines the order of the derivative (allowed values are 1 and 2), the parameter WindowSize specifies the size of the window used to smooth the derivative. WindowSize must be defined by an odd number between 5 and 25. The Group parameter controls the spectral group number of the new (derived) spectrum. The parameter Feedback determines whether a progress bar indicates the progress of the calculations.

The function returns the following error codes:

 0 ... everything is OK
-1 ... invalid order
-2 ... WindowSize is out of range
-3 ... WindowSize must be odd
-4 ... WindowSize must be less than half of the spectral range
-5 ... FirstLayer and/or LastLayer are out of range
-6 ... group number is already used
-7 ... invalid group number


Last Update: 2018-Jšn-23