Learn R Programming

fdapace (version 0.1.1)

CreateModeOfVarPlot: Functional Principal Component Analysis mode of variation plot

Description

Create the k-th mode of variation plot around the mean. The red-line is the functional mean, the grey shaded areas show the range of variations around the mean: $\pm Q \sqrt{\lambda_k} \phi_k$ for the dark grey area Q = 1, and for the light grey are Q = 2.

Usage

CreateModeOfVarPlot(fpcaObj, k = 1, ...)

Arguments

fpcaObj
An FPCA class object returned by FPCA().
k
The k-th mode of variation to plot (default k = 1)
...
Additional arguments for the 'plot' function.

Examples

Run this code
set.seed(1)
n <- 20
pts <- seq(0, 1, by=0.05)
sampWiener <- Wiener(n, pts)
sampWiener <- Sparsify(sampWiener, pts, 10)
res <- FPCA(sampWiener$yList, sampWiener$tList, 
            list(dataType='Sparse', error=FALSE, kernel='epan', verbose=TRUE))
CreateModeOfVarPlot(res)

Run the code above in your browser using DataLab