Learn R Programming

pfica (version 0.1.0)

kffobi: Smoothed functional ICA in terms of principal components

Description

This function computes the ordinary ICA procedure from a penalized principal component expansion (also known as Karhunen-Lo<U+00E8>ve expansion) whose basis, the eigenfunctions of the covariance matrix operator, is expressed in terms of basis functions (Fourier, B-splines...). The estimation method is based on the use of fourth moments (FOBI), in which it is assumed that the independent components have different kurtosis values. The proposed algorithm can be considered an extension of the IC model proposed in Li et al. (2015). This function provides more accurate estimates than ffobi and was used in Vidal (2020) to identify artifactual independent curves in bioelectrical signals.

Usage

kffobi(fdx, ncomp = fdx$basis$nbasis, eigenfPar = fdPar(fdx),
       pr = c("fdx", "fdx.st", "KL", "KL.st"),
       center = FALSE, plotfd = FALSE)

Arguments

fdx

a functional data object obtained from the fda package.

ncomp

number of independent components to compute.

eigenfPar

a functional parameter object, obtained from the fda package, that defines the principal component functions to be estimated.

pr

the functional data object to project into the space spanned by the eigenfunctions of the FOBI operator. To compute the independent components, the usual procedure is to use KL.st, the standardized principal component expansion. Thus, if pr is not supplied, KL.st is used.

center

a logical value indicating whether the mean function has to be subtracted from each functional observation.

plotfd

a logical value indicating whether to plot the eigenfunctions of the FOBI operator.

Value

a list with the following named entries:

eigenbasis

a functional data object for the eigenfunctions or independent factors.

kurtosis

a numeric vector giving the kurtosis associated to each independent component vector.

scores

a matrix whose column vectors are the independent components.

Details

Note that kffobi first computes the (penalized) functional PCA; see Aguilera and Aguilera-Morillo (2013) for a detailed discussion. Thus here, the IC model for functional data consists in performing the multivariate ICA of a transformation of the principal component coordinate vectors.

Let \(x=(x_{i}(t)\colon i=1,\ldots,n;t\in T)\) be a set of functions in a finite-dimensional space spanned by a basis of functions \(\{\phi_{1}(t),\ldots,\phi_{p}(t)\}\). Assume that the principal component expansion of \(x\) is given by $$x_{i}^{(q)}\left(t\right)=\sum_{j=1}^{q}z_{ij}f_{j}\left(t\right)$$ where \((z_{ij})_{n\times q}=Z\) is the matrix of principal components and \(f_j\) the principal factors of \(x\). Notice that \(f_j\) can be expressed in terms of basis functions, i.e. \(f_{j}(t)=\phi(t)'b_{j}\), where the coordinates \(b_j\) are computed from the FPCA of \(x\). The ICA procedure consists of the same steps as the ones described in ffobi, but replacing the matrix \(A\) by \(Z\). As the orthogonalization of the basis functions is implemented in the FPCA algorithm, now \(\int_{T}f_{j}(t)f_{j'}(t)dt=I_{q};\forall j,j'=1,\ldots,q.\), where \(I_{q}\) denotes the identity matrix. As such, the ICA procedure from a principal component expansion is easy to compute.

References

Aguilera, AM. and MC. Aguilera-Morillo (2013). <U+201C>Penalized PCA approaches for B-spline expansions of smooth functional data<U+201D>. In: Applied Mathematics and Computation 219(14), pp. 7805<U+2013>7819.

Li, B., G. Van Bever, H. Oja, R. Sabolov<U+00E1>, and F. Critchley (2015). <U+201C>Functional independent component analysis: an extension of the fourth-orderblind identification.<U+201D> Submitted.

Miettinen, J., K. Nordhausen, and S. Taskinen (2017). <U+201C>Blind source separation based on joint diagonalization in R: The packages JADE and BSSasymp<U+201D>. In: Journal of Statistical Software 76.2, pp. 1<U+2013>31.

Ramsay, J. and B. Silverman (2005). Functional Data Analysis. Springer.

Vidal, M. (2020). Functional Independent Component Analysis in Bioelectrical Signal Processing. MA thesis. Universidad de Granada.

See Also

kd, ffobi

Examples

Run this code
# NOT RUN {
## foetal_ecg data
library(fda)
dataset <- matrix(
  scan("https://www.jstatsoft.org/index.php/jss/article/downloadSuppFile/v076i02/foetal_ecg.dat"),
  2500, 9, byrow = TRUE);
X <- dataset[1:1000, 2:9]
arg <- 1:1000
basis <- create.fourier.basis(rangeval=c(min(arg), max(arg)), nbasis=301, basisvalues=TRUE)
x <- Data2fd(X, argvals=arg, basis)
## Penalization can be considered:
#Lfdobj <- vec2Lfd(c(0,(2*pi/diff(4))^2,0), 4)
#hm <- fdPar(base, Lfdobj, lambda=2)
## Select the number of components with the kurtosis distance:
#kurt.dist <- kd(x, qmax = 8)
aci <- kffobi(x, 7, plotfd = TRUE)
# }

Run the code above in your browser using DataLab