rowmiss
Dear Stata user,
I will create mean scores for a selection of variables, an I need to take into account missing values. The first command works fine, but for the second one “t1_miss_ boundaries” I got the following error message” too many variables specified r(103)”. I can’t understand this since there are the same amount of variables in “t1_miss_control” as in “t1_miss_ boundaries”.
First command ( works fine)
egen t1_miss_control=rowmiss (Q10a Q10b Q10c Q10d Q10e_r Q10f)
egen t1_control=rowmean (Q10a Q10b Q10c Q10d Q10e_r Q10f)if t1_miss_control<4
Second command ( error message “” too many variables specified r(103)”.)
egen t1_miss_ boundaries=rowmiss (Q11a Q11b Q11c Q11d Q11e Q11f)
egen t1_ boundaries=rowmean (Q11a Q11b Q11c Q11d Q11e Q11f)if t1_miss_ boundaries<4
Can someone see what’s wrong in the second command?
Many thanks
0 Response to rowmiss
Post a Comment