Date: Sun, 13 Apr 1997 12:15:08 EDT
Reply-To: gene shackman <gxs03@HEALTH.STATE.NY.US>
Sender: "SPSSX(r) Discussion" <SPSSX-L@UGA.CC.UGA.EDU>
From: gene shackman <gxs03@HEALTH.STATE.NY.US>
Subject: transforming data file
hi,
I had posted a question on how to change a data file from individuls
to families, or rearranging multiple records into one record. Several
people responded, showing how to use vectors and aggregates. Many
thanks to you!
However, in using spss for windows, I run into a problem in that
after I do the aggregates, nothing seems to happen. That is, I
seem to still see the original data set, untransformed, and I dont
know where the new transformed data set is. One person did say to
use 'write', but even with that, I don't seem to be able to access
the transformed data set. I am not too familiar with spss for windows,
so I guess there is something more I should be doing to get to this
transformed data set. What?
In general, I read in the data set, do some computes, then the
aggregate. In one example (part shown below), I write an outfile,
but then how do I get to the outfile?
Thanks!
gene shackman
nys dept of health
gxs03@health.state.ny.us
---------------------------
VECTOR VPID(9A3) VFID(9A4) VOTH(9A4).
COMPUTE VPID(X)=PID.
COMPUTE VFID(X)=FID.
COMPUTE VOTH(X)=OTH.
AGGREGATE OUTFILE=*
/BREAK=FID
/VPID1 TO VPID9=MAX(VPID1 TO VPID9)
/VFID1 TO VFID9=MAX(VFID1 TO VFID9)
/VOTH1 TO VOTH9=MAX(VOTH1 TO VOTH9).
WRITE OUTFILE=out
/VPID1 VFID1 VOTH1 VPID2 VFID2 VOTH2 VPID3 VFID3 VOTH3
VPID4 VFID4 VOTH4 VPID5 VFID5 VOTH5 VPID6 VFID6 VOTH6
VPID7 VFID7 VOTH7 VPID8 VFID8 VOTH8 VPID9 VFID9 VOTH9.
|