pca {rexposome} | R Documentation

## Creation of an ExposomePCA from an ExposomeSet.

### Description

Method to calculate a PCA based on the exposures of an ExposomeSet. Only numerical-exposures (non categorical) will be computed. The function resurns an ExposomePCA object. This PCA is performed by using FactoMineR package.

### Usage

    pca(object, npc = 10, pca = FALSE, ...)

### Arguments

`object` | `ExposomeSet` which exposures will be used for the PCA
`npc` | (by default 10) number of dimensions kept in the results
`pca` | (default `FALSE`) Set to `TRUE` to Perform PCA (only numerical variables) or `FALSE` to perform FAMD (numerical and categorical)
`...` | Arguments to be passed to imputeFAMD

### Value

An `ExposomePCA` with the values of the PCA.

### See Also

plotPCA to plot the PCA values of an ExposomePCA, clustering to see how the exposures can cluster samples, correlation to compute the correlation between exposures

### Examples

    data("exposome")
    epca <- pca(expo[12:20, ])

[Package rexposome version 1.14.1 Index]