

Saving factor scores for all observat... 

Message/Author 


I have a set of data which I divided into a training subset and a validation subset. There is a column called TRAIN with a value of 1 indicating an entry is in the training set. I wish to use only the training data to fit the model. but I wish Mplus to generate factor score for the whole set of data, what is the easiest way of doing so. Currently I have: VARIABLE: USEOBSERVATION = (TRAIN EQ 1) but SAVEDATA: FILE is res.dat ; SAVE = FSCORES; only generate factor scores for the training set. Do I have to setup a new model and manually putting in the factor loadings from this result in a new zero dof CFA to generate factor scores for the validation data? Is there an easier way? 


Yes, you would need to do that. Use the SVALUES option of the OUTPUT command to obtain input with the results as starting values. Change * to @ and use that input and the validation data to generate factor scores for the validation data. 


Thank you very much for the promt reply, that's a real time saver! 

Back to top 

