| .fps_fpca | R Documentation |
Performs Functional Principal Component Analysis on a matrix of functional
observations using a B-spline basis expansion, then retains enough components
to explain at least 'pve' of the total variance. Accepts either an n x T
numeric matrix or an fd object from the fda package.
.fps_fpca(X, pve = 0.95, t_grid = NULL, domain = NULL, nbasis = NULL)
X |
n x T numeric matrix of observed functional data (rows = subjects),
or an |
pve |
Proportion of variance explained threshold (default 0.95). |
t_grid |
Numeric vector of observation time points (length T).
Inferred from |
domain |
Numeric vector c(a, b) giving the domain of the functions.
Inferred from |
nbasis |
Number of B-spline basis functions. If NULL, set automatically. |
A named list with components:
scr |
n x L matrix of FPC scores. |
efn |
T x L matrix of eigenfunction values evaluated on t_grid. |
mean |
Numeric vector of length T: mean function evaluated on t_grid. |
eval |
Numeric vector of eigenvalues (all, not just L). |
varprop |
Numeric vector of variance proportions for retained components. |
perc |
Cumulative variance proportions (all components). |
pca_fd |
The raw |
L |
Number of retained components. |
t_grid |
The t_grid used. |
domain |
The domain used. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.