version 0.2.3 (positive)
This version of prospectr
is now available on CRAN
New features
-
The
kenStone
function now includes a new feature that allows to initialize the
calibration sample search with a user-defined subset of observations (which are
to be included in the final calibration subset). Thanks to Thorsten Behrens and
Philipp Baumann for suggesting this feature. -
The gap-segment derivatives (
gapDer
) function now allows for high order
derivatives. In previous versions the function only allowed up to derivatives of
4th order, in this version the the function accepts as derivative order
any integer larger than 1.
Improvements and fixes
-
binning()
a bug in the creation of the binning groups has been fixed. This bug
is in fact inherited from a problem in thefindInterval()
function. The breaks
(given in the vec arument) might get corrupted when they contain many decimal
places. These breaks (in vec) are used to define the final bins. The problem in
the binning function was that when a frequency
variable (e.g. wavelength) was exactly on the left of the bin
range the variable was assigned to the next bin. In some cases this lead to
small discrepancies in the in the computation of the mean of the bins. -
spliceCorrection()
now accepts one or two values as input for the splice
argument. Previously it only accepted a vector of length two. For example, now it
corrrects for splice steps of spectra that originates from spectrometers
with two detectors (i.e. it corrects for the potential abrupt transition
betwteen the two detectors). -
An extra sanity check has been added to the
read_nircal()
function. The
function evaluaes whether it is indeed a file properly produced by the BUCHI
nircal software. -
There was a bug in the filter for the 3rd order derivative in gap segment
derivative (gapDer
) function. One of the factors in the filter had a wrong
negative sign. -
There was a bug in the
read_nircal
function. It emerged only in some files and
prevented the function from reading the Description field properly
Changes
- In the
msc()
function the argumentreference_spc
has been renamed to
ref_spectrum
to emphasize that its input must be is a vector and not a
matrix of spectra.