At 09:12 AM 1/23/2010, Dr. Guenther R. Vollmer wrote:
Is there a special procedure in
SPSS statistics to show only cases with n>5 for a
specific variable in the output ?
If you have multiple records per case; a variable or variables
"CASEID" that identifies the records in a case; and 'n' means
the number of records for that case, then (untested)
AGGREGATE OUTFILE=* MODE=ADDVARIABLES
/BREAK = CASEID
/CaseN "'n' (number of records) for this case" =
NU.
You can then create a variable that distinguishes >5 from
<=5 (also untested):
RECODE CaseN
(LO THRU 5 = 0)
(5 THRU HI = 1) INTO CaseN5.
FORMATS CaseN5 (F2).
VAR LABEL CaseN5 "Whether 'n' (number of records) for case
>5".
VAL LABEL CaseN5
0 '<= 5'
1 '> 5'
.
You can then use either variable to select cases, filter
cases, or whatever you choose.
Does this do it for you?
=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (not to SPSSX-L), with no body text except the
command. To leave the list, send the command
SIGNOFF SPSSX-L
For a list of commands to manage subscriptions, send the command
INFO REFCARD