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 (July 2006)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
=========================================================================
Date:         Fri, 21 Jul 2006 12:19:15 -0400
Reply-To:     Edward Boadi <eboadi@abhct.com>
Sender:       "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:         Edward Boadi <eboadi@abhct.com>
Subject:      Re: 10 most frequent occurring values of a multiple response  set
Comments: To: Richard Ristow <wrristow@mindspring.com>,
          "Beadle, ViAnn" <viann@spss.com>
Content-Type: text/plain; charset="iso-8859-1"

Thanks Richard + Beadle for your syntax on the above subject.

I have some couple of questions.

Consider the syntax : . . . GET FILE='C:\Program Files\SPSS\originaldata.sav'. MATCH FILES /FILE=* /TABLE='ranked_data' /BY z. SELECT IF (nrank <= 10). EXECUTE. . . .

Where 1. ranked_data contains aggregated data with variables z and nrank 2. originaldata.sav is the original data file with variables x,y1,y2,z1,z2 and z3 3. z variable was created from the aggregation of z1,z2 and z3

The syntax above is suppose to keep only cases with z1 , z2 and Z3 are in the ranked data file (nrank <= 10). But after donig my analysis I still get values of z 1, z2 and z3 that are not in the ranked data file.

Please advice.

Regards to all.

-----Original Message----- From: Richard Ristow [mailto:wrristow@mindspring.com] Sent: Friday, July 21, 2006 12:46 AM To: SPSSX-L@LISTSERV.UGA.EDU Cc: Edward Boadi; Beadle, ViAnn Subject: Re: 10 most frequent occurring values of a multiple response set

At 04:28 PM 7/20/2006, Beadle, ViAnn wrote:

>Compute some variable which is a combination of all three values. For >example if z1, z2, and z3 take on two[-digit] values you'll need some >thing like: > >Compute z=z1 + z2*1000 + z3*100000. > >The second step is to rank occurrences, not values. > >You need to use aggregate to capture the occurrences into a variable, >using the N function and z as your break variable.

Etc. I think this is exactly right, except why "compute some variable which is a combination of all three values"? AGGREGATE is perfectly happy with BREAKing on multiple variables. I'd suggest

DATASET DECLARE ranked_data. AGGREGATE /OUTFILE='ranked_data' /BREAK=z1 z2 z3 /N=N.

instead of

COMPUTE Z=z1+z2*1000+z3*100000. DATASET DECLARE ranked_data. AGGREGATE /OUTFILE='ranked_data' /BREAK=z


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