Reads data incorrectly PreviousNext
Mplus Discussion > Structural Equation Modeling >
 Anonymous posted on Saturday, June 28, 2003 - 9:34 pm
I am trying to fit a SEM model with a number of y categorical variables. In reading the data though it says "Categorical variable Y4 contains less than 2 categories" where as I can clearly see that the .txt file that I am supplying contains values 1, 2, 3, 4, and 5 (ordered categories). I tried creating that file on Excel and SPSS but still the message is the same. What might have gone wrong?
 Linda K. Muthen posted on Saturday, July 05, 2003 - 9:02 am
With categorical outcomes, any observation with a missing value on one or more analysis variables is not included in the analysis (listwise deletion). I would imagine that this is what is happening. After listwise deletion, y4 contains only one category. If this is not the case, send the data and input and I will find the explanation.
 Anonymous posted on Monday, February 16, 2004 - 12:04 pm
Could you please see what I am doing wrong here (i am trying to create a categorical group variable)?


if (gleason gt 6) then group5=1;
if (gleason le 6) and (gleason>0) then group5=0;

NAMES ARE ID..oareax group4;

CATEGORICAL is group5;


age1x wst_hipx trigplx hdlx
cpepx insulinx glucosex hgbx group5;

ANALYSIS: type=meanstructure;

MODEL: group5 ON age1x wst_hipx IR;
IR ON age1x wst_hipx;

IR BY trigplx* hdlx cpepx insulinx
glucosex hgbx;

age1x WITH wst_hipx;

OUTPUT: stand tech2;

*** ERROR in Variable command
Unknown variable(s) in CATEGORICAL option:
 Linda K. Muthen posted on Monday, February 16, 2004 - 12:52 pm
In Version 2.14, a variable listed on the CATEGORICAL statement cannot be a new variable created in DEFINE. See pages 55-56 of the Mplus User's Guide. Use the name from one of the other variables in the NAMES statement that is not on the USEV statement. That should work. This will be changed in Version 3.
 May Guo posted on Tuesday, July 08, 2008 - 1:33 pm

I am tring to import data from SPSS to MPlus. I changed all the missing value to -9, saved the SPSS file to .dat format. When I check the .dat file with notepad, it seems that the data are read correctly. However after I imported data to MPlus and run the frequency, the means of any varaibles with missing values are different from what I get from SPSS. The difference is not due to decimal rounding (e.g. M=4.02 in SPSS vs. M = 4.33 in Mplus)

I also tried to run CFA using Mplus, the model is not converged. But using exactly the same data to run CFA in AMOS, the model fit is reasonably good (CFI=.963, RMSEA=.064, NFI=.958).

Can anyone suggest what might be the problem?

 Linda K. Muthen posted on Tuesday, July 08, 2008 - 2:03 pm
The default in Mplus is to use all available data (TYPE=MISSING). I believe the sample statistics in SPSS use the number of observations for each variable that are not missing. Different n's is the most likely reason for the discrepancy.

The convergence problem may be due to large variances. See your sample statistics. If you have large variances, you can rescale the variances by dividing by a constant using the DEFINE command. We recommend keeping variances between one and ten. If this does not help, please send your input, data, output, and license number to
 Nikolaos Stavrakakis posted on Thursday, August 12, 2010 - 1:52 am
Hello Linda,

I am trying to run the model fit for a SEM with 5 imputed datasets where I get this error message "Test of model fit, standard errors and sample statistics are not computed. This is due to zero successful imputations. chech tech 9"

When I check tech9 for all imputed datasets this error message appears "The degrees of freedom for this model are negative. the model is not identified....check your model. The model estimation terminated normally. The standard errors of the model parameter estimates could not be computed....problem involving parameter 28...."

Can you please explain what the problem is here? Is there something wrong with the imputed datasets (a quick inspection did not show anything there)? or is there not enough information in the data to estimate all of the parameters that i have specified?

thanks for your time and efforts
 Linda K. Muthen posted on Thursday, August 12, 2010 - 9:27 am
It sounds like the problem is with your model not the data. Please send the full output and your license number to
 Denise Aske posted on Tuesday, May 27, 2014 - 10:49 am
Hello Linda,

I keep receiving the error: Unrecognized symbol in data file: symbol at record #: 1, field #: 4
Field 4 is the same as fields 1-3, which are numbers in the general format. I'm not sure why I am receiving this message.
 Linda K. Muthen posted on Tuesday, May 27, 2014 - 11:59 am
Please send the output, data set, and your license number to
Back to top
Add Your Message Here
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Options: Enable HTML code in message
Automatically activate URLs in message