Description Usage Arguments Value See Also Examples
View source: R/MFPCAfit_methods.R
Plots the eigenfunctions as perturbations of the mean (i.e. the mean function plus/minus a constant factor times each eigenfunction separately). If all elements have a one-dimensional domain, the plots can be combined, otherwise the effects of adding and subtracting are shown in two separate rows for each eigenfunction.
1 2 3 4 5 6 7 8 |
x |
An object of class |
plotPCs |
The principal components to be plotted. Defaults to all
components in the |
stretchFactor |
The factor by which the principal components are
multiplied before adding / subtracting them from the mean function. If
|
combined |
Logical: Should the plots be combined? (Works only if all
dimensions are one-dimensional). Defaults to |
... |
Further graphical parameters passed to the plot.funData functions for functional data. |
A plot of the principal components as perturbations of the mean.
1 2 3 4 5 6 7 8 9 10 11 12 | # Simulate multivariate functional data on one-dimensonal domains
# and calculate MFPCA (cf. MFPCA help)
set.seed(1)
# simulate data (one-dimensional domains)
sim <- simMultiFunData(type = "split", argvals = list(seq(0,1,0.01), seq(-0.5,0.5,0.02)),
M = 5, eFunType = "Poly", eValType = "linear", N = 100)
# MFPCA based on univariate FPCA
PCA <- MFPCA(sim$simData, M = 5, uniExpansions = list(list(type = "uFPCA"),
list(type = "uFPCA")))
# Plot the results
plot(PCA, combined = TRUE) # combine addition and subtraction in one plot
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.