Loadings and scores from fastICA?
ICA and PCA both model the data as a product of two matrices (usually called something like components or loadings & weights or scores). It's how those matrices are constructed that differs. PCA is often a first step in doing ICA. I'd suggest reading the ICA tutorial by *Aapo Hyv?rinen and Erkki Oja * (http://www.cis.hut.fi/aapo/papers/IJCNN99_tutorialweb/) -- it's an excellent introduction. -- Tony Plate
Joel F?rstenberg-H?gg wrote:
Ok, so then the S gives the individual components, good. Thanks Tony! But what about the principal components from the PCA plot, how are they calculated? And are the linear mixing matrix A really the same as the loadings/weights? There must be different loadings for the PCA and ICA right? Best regards, Joel
Date: Wed, 11 Nov 2009 14:29:06 -0700 From: tplate at acm.org To: joel_furstenberg_hagg at hotmail.com CC: r-help at r-project.org Subject: Re: [R] Loadings and scores from fastICA? The help for fastICA says: The data matrix X is considered to be a linear combination of non-Gaussian (independent) components i.e. X = SA where columns of S contain the independent components and A is a linear mixing matrix. The value of fastICA is a list with components "S" (the estimated
source matrix) and "A" (the estimated mixing matrix). Are these what you want?
-- Tony Plate Joel F?rstenberg-H?gg wrote:
Hi all, Does anyone know how to get the independent components and
loadings from an Independent Component Analysis (ICA), as well as principal components and loadings from a Pricipal Component analysis (PCA) using the fastICA package? Or perhaps if there's another way to do ICAs in R?
Below is an example from the fastICA manual
if(require(MASS))
{
x <- mvrnorm(n = 1000, mu = c(0, 0), Sigma = matrix(c(10, 3, 3,
1), 2, 2))
x1 <- mvrnorm(n = 1000, mu = c(-1, 2), Sigma = matrix(c(10, 3, 3,
1), 2, 2))
X <- rbind(x, x1) a <- fastICA(X, 2, alg.typ = "deflation", fun = "logcosh", alpha =
1, method = "R", row.norm = FALSE, maxit = 200, tol = 0.0001, verbose = TRUE)
par(mfrow = c(1, 3)) plot(a$X, main = "Pre-processed data") plot(a$X%*%a$K, main = "PCA components") plot(a$S, main = "ICA components") } Best regards, Joel
_________________________________________________________________ Hitta k?rleken i vinter! http://dejting.se.msn.com/channel/index.aspx?trackingid=1002952 [[alternative HTML version deleted]]
------------------------------------------------------------------------
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. ------------------------------------------------------------------------ kolla in resten av Windows LiveT. Inte bara e-post - Windows LiveT ?r mycket mer ?n din inkorg. Mer ?n bara meddelanden <http://www.microsoft.com/windows/windowslive/>