Factor Analysis-factanal function
Dear Ricardo, Factor scores are linear combinations of the original variables and therefore to get factor scores, factanal() needs the data, not just the correlation matrix among the variables. Perhaps what you want is the factor-score coefficient matrix. Since you're apparently using a varimax rotation, which is orthogonal, you could compute the factor-score coefficients from the correlation matrix among variables and the factor loadings. To do this for an oblique rotation, you'd need the factor-correlation matrix, which factanal() sadly and inexplicably doesn't report. All this is academic, however, because if you don't have the original data from which to compute factor scores, what use are the factor-score coefficients? I hope this helps, John ------------------------------ John Fox, Professor Department of Sociology McMaster University Hamilton, Ontario, Canada web: socserv.mcmaster.ca/jfox
-----Original Message----- From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org]
On
Behalf Of "Oca?a Riola, Ricardo" Sent: January-30-09 5:30 AM To: r-help at r-project.org Subject: [R] Factor Analysis-factanal function Dear friends, I'm using R to produce the following Factor Analysis:
matriz.cor<-hetcor(matrix(as.factor(data), ncol=variables,
byrow=T))$correlations
factanal(x=data, factors=2, covmat=matriz.cor, scores='regression')
Then the screen output shows the following message: Error en factanal(x = data, factors = 2, covmat = matrix, : requested scores without an 'x' matrix Do you know some additional function in order to produce a matrix of
scores
when 'covmat' parameter is used?. Thank you. [[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.