Learn R Programming

fdapace (version 0.1.1)

FPCA: Functional Principal Component Analysis

Description

FPCA for dense or sparse functional data.

Usage

FPCA(y, t, optns = list())

Arguments

y
A list of n vectors containing the observed values for each individual. Missing values specified by NAs are supported for dense case (dataType='dense').
t
A list of n vectors containing the observation time points for each individual corresponding to y.
optns
A list of options control parameters specified by list(name=value). See `Details'.

Value

  • A list containing the following fields:
  • sigma2Variance for measure error.
  • lambdaA vector of length K containing eigenvalues.
  • phiAn nWorkGrid by K matrix containing eigenfunctions, supported on workGrid.
  • xiEstA n by K matrix containing the FPC estimates.
  • xiVarA list of length n, each entry containing the variance estimates for the FPC estimates.
  • obsGridThe (sorted) grid points where all observation points are pooled.
  • muA vector of length nObsGrid containing the mean function estimate.
  • workGridA vector of length nWorkGrid. The internal regular grid on which the eigen analysis is carried on.
  • smoothedCovA nWorkGrid by nWorkGrid matrix of the smoothed covariance surface.
  • fittedCovA nWorkGrid by nWorkGrid matrix of the fitted covariance surface, which is guaranteed to be non-negative definite.
  • optnsA list of actually used options.
  • bwMuThe selected (or user specified) bandwidth for smoothing the mean function.
  • bwCovThe selected (or user specified) bandwidth for smoothing the covariance function.
  • rhoA regularizing scalar for the measurement error variance estimate.
  • cumFVEA vector with the percentages of the total variance explained by each FPC. Increase to almost 1.
  • FVEA percentage indicating the total variance explained by chosen FPCs with corresponding 'FVEthreshold'.
  • criterionValueA scalar specifying the criterion value obtained by the selected number of components with specific methodSelectK: FVE,AIC,BIC values or NULL for fixedK.
  • inputDataA list containting the original 'y' and 't' lists used as inputs to FPCA. NULL if 'lean' was specified to be TRUE.

Details

Available control options are [object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

References

Yao, F., Mueller, H.G., Clifford, A.J., Dueker, S.R., Follett, J., Lin, Y., Buchholz, B., Vogel, J.S. (2003). "Shrinkage estimation for functional principal component scores, with application to the population kinetics of plasma folate." Biometrics 59, 676-685. (Shrinkage estimates for dense data)

Yao, Fang, Hans-Georg Mueller, and Jane-Ling Wang. "Functional data analysis for sparse longitudinal data." Journal of the American Statistical Association 100, no. 470 (2005): 577-590. (Sparse data FPCA)

Liu, Bitao, and Hans-Georg Mueller. "Estimating derivatives for samples of sparsely observed functions, with application to online auction dynamics." Journal of the American Statistical Association 104, no. 486 (2009): 704-717. (Sparse data FPCA)

Castro, P. E., W. H. Lawton, and E. A. Sylvestre. "Principal modes of variation for processes with continuous sample curves." Technometrics 28, no. 4 (1986): 329-337. (Dense data FPCA)

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))
CreateCovPlot(res, 'Fitted')

Run the code above in your browser using DataLab