Date: Thu, 3 Mar 2011 01:23:33 -0500
Reply-To: Rich Ulrich <firstname.lastname@example.org>
Sender: "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From: Rich Ulrich <email@example.com>
Subject: Re: Split a variable into 5 groups and compute usual stats
Content-Type: text/plain; charset="iso-8859-1"
The tough part is what to do with ties - which you did not mention -
and how to make sure that the last group is smallest.
Check out "RANK" and see what is convenient to use. You can ask
for quintiles. Or simple percentiles. You can specify how to
handle ties and certain definitions for ranking instead of
Then you can group the defined percentiles, if that is what you
get, according to whatever guidelines you would apply by hand.
> Date: Wed, 2 Mar 2011 20:12:45 -0800
> From: firstname.lastname@example.org
> Subject: Split a variable into 5 groups and compute usual stats
> To: SPSSX-L@LISTSERV.UGA.EDU
> Hi All
> SPSS 18.0 (Windows XP)
> Would you please help me figure out how to split a sorted variable
> SOLD$ into 5 groups (20% each, rounded up. The first 4 groups from
> lowest to highest should be equal, and the last, highest priced, could
> be higher or lower), and then compute usual stats (e.g., mean, N,
> median, min, max, SD, etc.) for each group within each year month and
> These results are based on a sample data file for 3 months in 2010
> (file is available if needed). However, my actual data file will have
> monthly data for the last 20 years with over a 100 districts. I cannot
> imagine recoding the SOLD$ variable manually. There must be an elegant
> solution for this.
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
For a list of commands to manage subscriptions, send the command