plot.specfeat: Plot Specfeat

plot.SpecfeatR Documentation

Plot Specfeat

Description

Plot spectra in objects of class Specfeat. Specfeats contain spectral data after applying a transformation such as continuum removal (see function transformSpeclib.

Usage

## S4 method for signature 'Specfeat'
plot(x, fnumber = 1:n_features(x), stylebysubset = NULL,
        changecol = TRUE, changetype = FALSE, autolegend = TRUE, new = TRUE,
        ...)

Arguments

x

Object to be plotted

fnumber

Subscript of feature(s) to be plotted

stylebysubset

Name of column in SI table to be used for colour.

changecol

Flag indicating if line colours change according to values in coloumn defined by stylebysubset

changetype

Flag indicating if line types change according to values in coloumn defined by stylebysubset

autolegend

Flag if legend is plotted.

new

Flag if a new plot should be started.

...

Further arguments passed to plot.default

Author(s)

Lukas Lehnert

See Also

nri, glm.nri, glm, cor.test,Nri-method, t.test,Nri-method, Specfeat

Examples

## Not run: 
data(spectral_data)

## Transform speclib
bd <- transformSpeclib(spectral_data, method = "sh", out = "bd")

##Example to isolate the features around 450nm, 700nm, 1200nm and 1500nm.
featureSelection <- specfeat(bd, c(450,700,1200,1500))

## Plot features
plot(featureSelection)

## Advanced plotting example
plot(featureSelection, 1:2, stylebysubset = "season")

plot(featureSelection, 1:2, stylebysubset = "season", changecol = FALSE, 
     changetype = TRUE)

## End(Not run)

hsdar documentation built on March 18, 2022, 6:35 p.m.