|
Hello Dominic
You need Aggregate for that.
Untested:
AGGREGATE OUTFILE * /BREAK vName
/Bloodpr = max(varnameRow2)
/Age = max(varnameRow4)
/...etc.
This creates one record for each vName.
It assumes that every variable has only one value (apart from the missing
ones) across the cases for one person. If not, you can use other aggregate
functions like mean. See the syntax reference.
Good luck
Antoon Smulders
----- Original Message -----
From: "Dominic Lusinchi" <dominic@farwestresearch.com>
Newsgroups: bit.listserv.spssx-l
To: <SPSSX-L@LISTSERV.UGA.EDU>
Sent: Saturday, February 12, 2005 8:33 AM
Subject: multiple rows per case unique info per field (variable)
> Dear Colleagues,
>
> Here is my issue:
>
> I have many (most) cases in the (SPSS) data file with multiple records.
> For
> example information on John Doe occupies 4 records (rows), so, for
> instance,
> his blood pressure is recorded is row 2 (so rows 1, 3, and 4 in that
> field/column/variable have no information), and his age in row 4 (so rows
> 1,
> 2, and 3 in that field/column/variable have no information), etc... What I
> would like to do is put all the information for John Doe in one record
> (row), so instead of having 4 rows for John Doe I want only one.
>
> Any suggestions would be appreciated. Thank you in advance.
>
> Dominic
> *********************************************************
> Dominic Lusinchi
> FAR WEST RESEARCH
> Demography-Survey Research-Applied Statistics
> San Francisco, California
>
> Voice: 415-664-3032
> Fax: 415-664-4459
> E-mail: dominic@farwestresearch.com
> Web: http://www.farwestresearch.com
> *********************************************************
>
|