coredata: Extract the Core Data of a colorSpec Object

Description Usage Arguments Value See Also

Description

functions for extracting the core data contained in a colorSpec object.

Usage

1
2
3
4
5
## S3 method for class 'colorSpec'
coredata( x, forcemat=FALSE )

## S3 method for class 'colorSpec'
as.matrix( x, ... )

Arguments

x

a colorSpec object

forcemat

if x has only 1 spectrum, return a matrix with 1 column instead of a vector

...

extra arguments ignored

Value

coredata

If x has organization equal to 'vector' then it returns x, unless forcemat is TRUE when it returns x as a matrix with 1 column.
If x has any other organization then it returns a matrix with spectra in the columns. All of the colorSpec attributes are stripped except the column names, and the row names are set to as.character(wavelength(x)).

as.matrix

a wrapper for coredata with forcemat=TRUE

See Also

organization



Search within the colorSpec package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.