Skip to content

completely intrinsic framework for Riemannian functional data analysis

License

GPL-3.0, BSD-3-Clause licenses found

Licenses found

GPL-3.0
LICENSE
BSD-3-Clause
license.txt
Notifications You must be signed in to change notification settings

linulysses/iRFDA

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

iRFDA

completely intrinsic framework for Riemannian functional data analysis

Example

clear;

% define the 2D hyperbolic manifold

mfd = hyperbolic();

d = mfd.d;

% synthetic mean function and Riemannian slope function on the manifold

m = 100; % #observations per curve

t = linspace(0.005,0.995,m);

theta_t = 2*t.^3+t.^2+t-2;

varphi_t = t.^3-t.^2+pi*t+1;

mu = [sinh(theta_t).*cos(varphi_t);sinh(theta_t).*sin(varphi_t);cosh(theta_t)];

K = 20;

phi = mdfourier(m,K,diag(ones(1,d)),t);

beta_coef = 1.5*(1./(1:K).^2);

betaZ = zeros(d,m); % coefficients of beta in the frame

for k = 1:K

betaZ = betaZ + beta_coef(k) * phi(:,:,k);

end

betaV = mfd.coef_to_log(mu,betaZ); % tangent-vector-valued beta

beta = mfd.Exp(mu,betaV); % beta on the manifold

%% generate Riemannian functional data

n = 100;

eigfunc = mdfourier(m,K,diag(ones(1,d)),t); % coefficients of eigenfunctions in the frame

lam = 1 ./ ((1:K).^2); % eigenvalues

xi = randn(n,K).* repmat(sqrt(lam(:)'),n,1); % RFPC scores

Z = zeros(d,m,n); % realizations of the coefficient process

for k = 1:K

xik = xi(:,k);

phik = eigfunc(:,:,k); % 

for i = 1:n

    Z(:,:,i) = Z(:,:,i) + (xik(i)*phik);
    
end

end

V = mfd.coef_to_log(mu,Z); % tangent-vector-valued functions

X = mfd.Exp(mu,V); % manifold-valued functions

%%

iRFPCA(X,mfd) % performance iRFPCA on X

About

completely intrinsic framework for Riemannian functional data analysis

Resources

License

GPL-3.0, BSD-3-Clause licenses found

Licenses found

GPL-3.0
LICENSE
BSD-3-Clause
license.txt

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages