LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (February 2009)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 18 Feb 2009 14:05:33 -0500
Reply-To:     Richard Ristow <wrristow@mindspring.com>
Sender:       "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:         Richard Ristow <wrristow@mindspring.com>
Subject:      Re: change varying records into one record per individual
Comments: To: Martin Sherman <MSherman@loyola.edu>
Comments: cc: "Oliver, Richard" <roliver@spss.com>,
          Clive Downs <clive.downs@READING.GOV.UK>
In-Reply-To:  <49996B54.7E13.0074.3@loyola.edu>
Content-Type: text/plain; charset="us-ascii"; format=flowed

At 01:34 PM 2/16/2009, Martin Sherman wrote:

>I have students applying to anywhere from 1 to 111 schools. They >will have a record for each school they apply to. I have whether the >school accepted them (0 vs 1-yes) and also whether they attended >that school (0 vs. 1-yes). I can add up these two variables and come >up with missing, 0, 1, or 2. Missing being that they did not apply >to that school. 0 is they applied but was not accepted, 1 if the >were accepted but did not enroll, and 2 if they were accepted and >enrolled. I now want to have a single record for each student so >that I have the students status in regard to all 111 schools. >Looking across the record I should see missing values, 0's, 1's, and >only one 2.

You have seen Richard Oliver's and Clive Downs's (correct) advice how to do this.

My advice is, don't do it. Any record with 111 instance of something is awkward. And (once more), SPSS is very good at handling multiple records, far clumsier at handling multiple instances within a record.

The following (though untested) should be a lot easier. Remember that AGGREGATE *replaces* the active file; make sure the original is stored safely and accessibly.

If each student has a value of a variable called "StdtID", and the two 0-1 variables are called "Accepted" and "Attended",

AGGREGATE OUTFILE=* /BREAK = StdtID /NAppl 'Number of schools applied to' = NU /NAcc 'Number of schools accepted at' = SUM(Accepted) /NAttnd 'Number of schools attended' = SUM(Attended).

===================== To manage your subscription to SPSSX-L, send a message to LISTSERV@LISTSERV.UGA.EDU (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


Back to: Top of message | Previous page | Main SPSSX-L page