pcaadd: Principal component analysis with reference spectra

Description Usage Arguments Value

Description

A PCA model is calculated after a multiple of the reference matrix is added to the data matrix.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
  ## S4 method for signature 'matrix,matrix'
pcaadd(x, reference, ...,
    ref.factor = 10, refcomps = seq_len(nrow(reference)))

  ## S4 method for signature 'hyperSpec,hyperSpec'
pcaadd(x, reference, ...)

  ## S4 method for signature 'hyperSpec,matrix'
pcaadd(x, reference, ...)

  ## S4 method for signature 'matrix,hyperSpec'
pcaadd(x, reference, ...)

  ## S3 method for class 'pcaadd'
 predict(object, newdata, ...)

Arguments

x

data matrix

reference

reference data points

...

further arguments are handed to prcomp, but center is always FALSE.

ref.factor

reference is multiplied by ref.factor * max (abs (range (x))) / max (abs (range (reference))) * nrow (x) / nrow (reference) before the PCA. This forces the first directions towards reference.

refcomps

the principal components that are attributed to the reference

object

pcaadd model

newdata

matrix with new observations.

Value

object of class "pcaadd"


cbmodels documentation built on May 31, 2017, 2:11 a.m.