Description Usage Arguments Value Author(s) References See Also Examples
SemimetricPCA
is a function that calculates a distance matrix based
on the PCA of the functional data. A Rcpp port of the
PCA-type semimetric function of Ferraty and Vieu.
1 2 3 4 | SemimetricPCA(Data1,
Data2,
q,
EigenVec = NULL)
|
Data1 |
Matrix with functional data (curves) each row one; n rows |
Data2 |
Matrix with a second set of functional data (curves) each row one; m rows |
q |
Number of principal components |
EigenVec |
The Eigenvectors based on DATA1 |
Semimetric
returns a list with:
semimetric
as the n x m - distance-matrix
EigenVec
The Eigenvectors based on DATA1, which can
be reused in following semimetric calculations
Simon Mueller simon.mueller@mathematik.uni-stuttgart.de
http://www.math.univ-toulouse.fr/staph/npfda/
Ferraty, F. and Vieu, P. Nonparametric Functional Data Analysis. Springer 2006.
Semimetric
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | # functional data sets
require (fds)
# fat spectrum dataset
X <- t(Fatspectrum$y)
# setup semimetric parameter
q <- 4
# calculate distance matrix
Dist1 <- SemimetricPCA (X[1:100, ],
X[101:150, ],
q)
# calculate distance matrix using Hhalf
Dist2 <- SemimetricPCA (X[1:100, ],
X[151:215, ],
q,
Dist1$EigenVec)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.