| spStat | R Documentation |
Calculate summary statistic spectra in hyperSpec object for all
spectra and by levels of factor variable by.
spStat(sp, by, FUN = mean, Name_of.by = as.character(match.call()$by), ...)
sp |
A hyperSpec object. |
by |
A grouping variable (either variable name of |
FUN |
A function to apply. |
Name_of.by |
(Do not change this!) The name of input |
...further |
arguments passed to |
A hyperSpec object that contains summary statistic. Additional
column .aggregate is added. In this column levels of
grouping variable are indicated.
This function is similar to aggregate,
just calculates additional statistic for all spectra. This
statistic is labeled by adding level .ALL) in variable
.aggregate and variable, that has the same name as by
(if Name_of.by si not modified).
Vilmantas Gegzna
aggregate
Other spHelper functions for spectroscopy and hyperSpec:
IQR_outliers(),
binning(),
file,
gapDer(),
hy2mat(),
hyAdd_Label_wl(),
hyAdd_Labels_PAP_PD_2014(),
hyAdd_Labels_TD2009(),
hyAdd(),
hyDrop_NA(),
hyGet_palette(),
hyRm_palette(),
mad_outliers(),
mean_Nsd(),
median_Nmad(),
plot_hyPalette(),
prepare_PAP_RK_2014__MATLAB_failui(),
read.OOIBase32(),
read.OceanView.header(),
read.OceanView(),
read.sp.csv2(),
read3csv2hy(),
replace_spc(),
sd_outliers(),
sp_class_perform()
spStat(Spectra2, gr)
spStat(Spectra2, by = gr, FUN = IQR)
## BUG:
# spStat(Spectra2, by = Spectra2$gr, FUN = IQR)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.