SAVEDATA command PreviousNext
Mplus Discussion > Growth Modeling of Longitudinal Data >
Message/Author
 Stephanie Fitzpatrick posted on Wednesday, March 11, 2009 - 10:56 am
Hello,

I am running some latent transition analysis and would like to further analyze the latent classes by subject number. However, every time I run SAVEDATA: File is ltams.txt;
SAVE = cprobabilities;

I get *** WARNING in Savedata command
(Err#: 9)
Error opening data save file:
ltams.txt
Data will not be saved.

Any suggestions?

Thanks
 Linda K. Muthen posted on Wednesday, March 11, 2009 - 11:45 am
You either have a path that is not correct or you don't have privileges to open the file. If you can't figure it out, please send the problem and your license number to support@statmodel.com.
 Stephanie Fitzpatrick posted on Friday, March 13, 2009 - 8:12 am
Thank you. I figured it out.

Stephanie
 Youngoh Jo posted on Thursday, December 22, 2011 - 7:48 pm
Hi!

Using the following command "SAVE IS CPROB" I got a new data set.

How can I get a new data set with the id variable?

Thanks in advance,
 Linda K. Muthen posted on Thursday, December 22, 2011 - 8:19 pm
Use the IDVARIABLE option of the VARIABLE command.
 Youngoh Jo posted on Friday, December 23, 2011 - 3:40 pm
Thanks Linda,

I am generating new data set which include the original id varialbe.
Below is the syntax I typied.

data: file is "C:\data\this.csv";
variable: NAMES ARE ID sc2-sc6;
USEVARIABLES ARE id sc2-sc6;
IDVARIABLE IS id;
classes = c (3);
ANALYSIS: TYPE = MIXTURE;

model: %overall%
i s | sc2@0 sc3@1 sc4@2 sc5@3 sc6@4;


OUTPUT: tech1 tech8 tech11 tech14;


SAVEDATA: file is "C:\data\new.sav";
SAVE IS CPROB;

How can I get new data which include the origianl id variable?

Thanks,
 Linda K. Muthen posted on Saturday, December 24, 2011 - 6:58 am
It should with what you show. Please send the full output and your license number to support@statmodel.com.
 Matt Hawrilenko posted on Tuesday, October 15, 2013 - 6:14 pm
Hello,

I'm trying to save model-predicted values in a growth curve model. The user guide explains how to save factor scores, but not how to do it for simpler growth models and I was unable to find a solution on the forums. Is this possible in the current version of Mplus?

Reviewers have requested we calculate the reliable change index and due to missing data, I've assumed that using predicted values would be the best route. Am I missing a better alternative?

Thanks very much.

Matt
 Linda K. Muthen posted on Wednesday, October 16, 2013 - 4:02 pm
You would need to create these model-predicted values in the DEFINE command and save them.
 Helen Li posted on Friday, September 19, 2014 - 5:58 pm
Dear Professor,

How can I save class probabilities and most likely class membership for each simulated data set? Thanks!
 Linda K. Muthen posted on Saturday, September 20, 2014 - 7:00 am
Use the CPROBABILITIES option of the SAVEDATA command.
 Helen Li posted on Saturday, September 20, 2014 - 8:24 am
Thank you, Professor! But if I simulated 100 sets of data, can I obtain class probabilities and most likely class membership for all these runs using some functions in MPlus? I hope my question makes sense. Thanks!
 Helen Li posted on Saturday, September 20, 2014 - 4:19 pm
Dear Professor, as per my last question, I'm pasting the codes:

Title: New data sets to be saved
data:
FILE IS simlist.dat; !a file that contains a list of names of the generated data
Type = Montecarlo;
variable:
names are y1-y4 x1 x2 c0;
USEVARIABLES ARE y1-y4;
classes = c(2);
Auxiliary = x1 x2;
analysis:
Type = mixture;
model:
%overall%
i s | y1@0 y2@1 y3@2 y4@3;
i* s*;
i with s*;
y1-y4*(ve);
[c#1*0];
%c#1%
[i*];
[s*];
%c#2%
[i*];
[s*];
Output:Tech9;
savedata: FILE IS simp.dat;
save = cprobabilities;

The codes ran very well except that I got the following warnings and so I couldn't save the new data sets. May I know how can I get the new data sets?

"*** WARNING in SAVEDATA command
The FILE option is not available for TYPE=MONTECARLO or TYPE=IMPUTATION.
The FILE option will be ignored.
*** WARNING in SAVEDATA command
The SAVE option is not available for TYPE=MONTECARLO or TYPE=IMPUTATION.
The SAVE option will be ignored.
2 WARNING(S) FOUND IN THE INPUT INSTRUCTIONS"

Thanks always for your help!!!
 Linda K. Muthen posted on Sunday, September 21, 2014 - 6:10 am
You would need to run each data set separately to save the files you want.
Back to top
Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action: