Learn R Programming

photobiology (version 0.9.16)

msmsply: Multi-spct transform methods

Description

Apply a function or operator to a collection of spectra.

Usage

msmsply(mspct, .fun, ...)

msdply(mspct, .fun, ..., idx = NULL, col.names = NULL)

mslply(mspct, .fun, ...)

msaply(mspct, .fun, ..., .drop = TRUE)

Arguments

mspct

an object of class generic_mspct or a derived class

.fun

a function

...

other arguments passed to .fun

idx

logical whether to add a column with the names of the elements of mspct, if NULL, the default, a column is added only if all members of mscpt are named.

col.names

character Names to be used for data columns.

.drop

should extra dimensions of length 1 in the output be dropped, simplifying the output. Defaults to TRUE

Value

a collection of spectra in the case of msmsply

a data frame in the case of msdply

a list in the case of mslply

an array in the case of msaply