Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Psych Package - Extract factor scores from fa.poly function

Tags:

r

I used fa.poly function for factor analysis of categorical manifest variables. I am now trying to extract the factor scores from the results. However, the str function indicates that factor scores are not "stored" in the results.

This is in contrast to the factor analysis function for continuous variables - fa - where the scores are stored in the results and can be extracted using results$scores

results <- fa.poly(inputdata, 4, fm = "pa", rotate = "oblimin")

results$scores gives NULL

VERSUS

results2 <- fa(inputdata, 4, fm = "pa", rotate = "oblimin")

results2$scores gives desired results

like image 931
GSM Avatar asked Oct 16 '13 17:10

GSM


2 Answers

Please update to 1.3.10.12 which was just added to Cran this weekend. I finally got around to allowing you to do this.

Bill

like image 65
William Revelle Avatar answered Nov 02 '22 02:11

William Revelle


Use the fa function, but add cor="poly" to the code to make sure it uses the polychoric correlation for ordinal variables:

results2 <- fa(inputdata, 4, fm = "pa", rotate = "oblimin", cor = "poly")
like image 36
Franck Avatar answered Nov 02 '22 03:11

Franck