apd_pca() fits a model.
apd_pca(x, ...) # S3 method for default apd_pca(x, ...) # S3 method for data.frame apd_pca(x, threshold = 0.95, ...) # S3 method for matrix apd_pca(x, threshold = 0.95, ...) # S3 method for formula apd_pca(formula, data, threshold = 0.95, ...) # S3 method for recipe apd_pca(x, data, threshold = 0.95, ...)
Depending on the context:
Not currently used, but required for extensibility.
A number indicating the percentage of variance desired from the principal components. It must be a number greater than 0 and less or equal than 1.
A formula specifying the predictor terms on the right-hand side. No outcome should be specified.
When a recipe or formula is used,
The function computes the principal components that account for
up to either 95% or the provided
threshold of variability. It also
computes the percentiles of the absolute value of the principal components.
Additionally, it calculates the mean of each principal component.