Description Usage Arguments Value Author(s) See Also Examples
Constructor for the SpatialSpectraDataFrame class. Creates a SpatialSpectraDataFrame object from scratch.
1 | SpatialSpectraDataFrame(coords, nir, data, coords.nrs = numeric(0), proj4string = CRS(as.character(NA)), match.ID = TRUE, bbox=NULL, wl=numeric(), id=data.frame(id=NA), units="nm")
|
wl |
a numeric vector giving the wavelengths at with the spectra have been measured |
nir |
a |
id |
a vector giving the unique id of each sample in the collection |
units |
a character giving the unit in which the wavelengths values are expressed |
data |
object of class |
coords |
numeric matrix or data.frame with coordinates (each row is a point) |
proj4string |
projection string of class CRS-class |
bbox |
bounding box matrix, usually NULL and constructed from the data, but may be passed through for coercion purposes if clearly needed |
coords.nrs |
numeric; if present, records the column positions where
in |
match.ID |
logical; if TRUE AND coords has rownames (i.e., coerced
to a matrix, |
a new "SpatialSpectraDataFrame"
object
Pierre Roudier pierre.roudier@gmail.com
spectra
, wl
, SpatialSpectraDataFrame-class
1 2 3 4 5 6 7 8 | # Creating a SpatialSpectraDataFrame object from scratch
my.wl <- 350:2500
my.id <- LETTERS[1:4]
my.nir <- matrix(runif(4*length(my.wl)), nrow=4)
my.data <- data.frame(foo = runif(4), bar = LETTERS[1:4])
my.coords <- matrix(runif(4), runif(4), ncol=2, nrow=4)
my.ssdf <- SpatialSpectraDataFrame(wl = my.wl, nir = my.nir, id = my.id, data = my.data, coords = my.coords)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.