Abstract
Estimation of functional linear mixed models for irregularly or sparsely sampled data based on functional principal component analysis.
Introduction
In classical Functional Data Analysis (FDA), researchers typically assume that functional observations, such as growth curves or acoustic signals, are recorded over a dense and perfectly aligned grid. However, real-world data in fields like phonetics, medicine, and longitudinal studies are often "messy"—characterized by sparse observations (few points per subject) or irregular sampling intervals. While standard linear mixed models can handle such irregularities, they often fail to capture the continuous, functional nature of the underlying process. The sparseFLMM package for R bridges this gap, providing a robust framework for estimating Functional Linear Mixed Models (FLMMs) using Functional Principal Component Analysis (FPCA).
Methodology: The Estimation Pipeline
The sparseFLMM package implements a four-stage estimation pipeline designed to handle complex experimental designs, including crossed and nested random effects:
- Mean Estimation: The smooth mean function is estimated using splines under an independence assumption. This stage can incorporate various covariates, including varying coefficients and smooth effects.
- Covariance Estimation: This is the core technical component. The package estimates smooth auto-covariances of functional random effects. To maintain computational efficiency, it employs a fast bivariate symmetric smoother (the
symmclass), which imposes symmetry constraints on spline coefficients. - Eigen-decomposition: Estimated auto-covariances are evaluated on a pre-specified grid and decomposed into eigenvalues and eigenfunctions, which are then rescaled for orthonormality.
- FPC Scoring: Finally, functional principal component (FPC) weights are predicted for the random effects, enabling subject-specific curve predictions.
Symmetry and Computational Efficiency
A key innovation in sparseFLMM is the use of symmetry as a computational shortcut. Since a covariance surface $G(s, t)$ is inherently symmetric ($G(s, t) = G(t, s)$), enforcing this constraint during the smoothing process reduces the number of parameters to be estimated and stabilizes the results.
As shown in the parameter specifications above, the package allows users to define the number of marginal basis functions and apply constraints like skew-symmetry to further refine the basis construction, which is critical for the symm class implementation.
Datasets and Applications
The package's utility is demonstrated using the acoustic dataset, a comprehensive phonetics dataset from a study on German consonant assimilation. It contains over 24,000 observations involving multiple speakers and target words, representing a "crossed" functional data structure where both speakers and words act as grouping levels for functional random intercepts. This dataset highlights the package's ability to handle large-scale, real-world functional data that standard FDA tools might struggle to process.
Conclusion and Limitations
sparseFLMM offers a scalable solution for modeling functional data with complex correlation structures. By integrating with the mgcv engine and the Functional Additive Mixed Model (FAMM) framework, it allows for rigorous hypothesis testing and variance decomposition. However, users must be mindful of computational intensity, particularly the quadratic influence of the evaluation grid resolution on processing time. Future developments may focus on deeper hierarchical nested models and broader testing of various basis function types.
Summary updated