choose_PCs.kurtosis: Selects the principle components (PCs) of sufficient kurtosis...

Description Usage Arguments Value

View source: R/choosePCs.R

Description

First, the largest PCs which together explain 90 retained, and smaller components are removed. Each PC is detrended (this can be disabled). The kurtosis cutoff is then the 90 distribution of kurtosis for Normal data of the same length as the PCs; it is estimated by simulation or calculated from the theoretical asymptotic distribution if the PCs are long enough.

Usage

1
choose_PCs.kurtosis(svd, kurt_quantile = 0.9, detrend = TRUE, n_sim = 5000)

Arguments

svd

An SVD decomposition; i.e. a list containing u, d, and v.

kurt_quantile

PCs with kurtosis of at least this quantile are kept.

detrend

Should PCs be detrended before measuring kurtosis? Default is TRUE. Recommended if observations represent a time series.

n_sim

The number of simulation data to use for estimating the sampling distribution of kurtosis. Only used if a new simulation is performed. (If n<1000 and the quantile is 90 If n>1000, the theoretical asymptotic distribution is used instead.)

Value

The original indices of the PCs which were retained, in order of decreasing kurtosis.


muschellij2/clever documentation built on Sept. 26, 2020, 3:54 p.m.