PCAnalysis {tofsims} | R Documentation

## Class PCAnalysis

### Description

Class `PCAnalysis` contains methods for simple PCA analyis

PCAnalysis is a PCA constructor function

### Usage

    PCAnalysis(dataObject, nComp, ...)

    PCAnalysis(dataObject, nComp, ...)

### Arguments

`dataObject` | object of type MassImage
`nComp` | integer number of components
`...` | further args

### Details

Class `PCAnalysis` contains methods for simple PCA analysis

PCAnalysis constructor function uses call by reference. The new object is put into the `analysis` slot of the dataObject on which PCA was calculated.

### Value

PCAnalysis class object

### Author(s)

Lorenz Gerber <lorenz.gerber@slu.se>

### Examples

    testImage<-MassImage('dummy')
    testImage<-PCAnalysis(testImage, 4)
    image(analysis(testImage, 1), comp = 1)
    ## Not run:
    library(tofsimsData)
    data(tofsimsData)
    testImage<-PCAnalysis(testImage, nComp = 4)
    image(analysis(testImage, 1), comp = 1)
    ## End(Not run)

[Package tofsims version 1.10.1 Index]