filter_pca: PCA filter

View source: R/filters.R

filter_pcaR Documentation

PCA filter

Description

filter_pca returns the first k principle components as filter values.

Usage

filter_pca(dat, k = 1, ...)

Arguments

dat

A numeric dataset matrix, rach row represents a data point and each column represents a predictive variable.

k

A scaler deciding the number of principle components to be returned

...

Optional arguments to cov.

Details

The PCA filter function is defined as f(x_i) = x_i^Tφ_{(1:k)}, where φ_{(1:k)} is the matrix of k eigenvectors associated with the k largest eigenvalues of cov(X), x_i is some data point and X is the data matrix.

Value

A matrix object of filter values.

Examples

tp_data = chicken_generator(1)
filter_pca(dat=tp_data[,-1])


TianshuFeng/SemiMapper documentation built on Sept. 16, 2022, 10:26 p.m.