Reputation: 93
I have 100 variables in a dataset and the first column is of ID number.There are some missing values in every variable. I want to list the ID number from each variable that have missing values.
Can someone suggest me the loop for getting the ID number of missing values of each variable in SPSS
Upvotes: 1
Views: 589
Reputation: 15
Here is a more primative solution. You can duplicate the ID column as in string format. Then recode SYSMIS and MISSING cells as "99" and use crosstabs.
Upvotes: -1
Reputation: 2929
You can use NMISS
function in a COMPUTE
command to assess if any cases along your chosen variables of interest have any missings (provided you have set missing values where appriopraite). With such a flag/new variable created it is then straight forward to indentify affected IDs.
Your code may look something like this:
COMPUTE CheckMissing=NMISS(V1 to V99).
TEMP.
SELECT IF CheckMissing>0.
FREQ ID.
Upvotes: 0