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 (August 2007)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 29 Aug 2007 13:18:51 -0400
Reply-To:     Richard Ristow <wrristow@mindspring.com>
Sender:       "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:         Richard Ristow <wrristow@mindspring.com>
Subject:      Re: All combinations of a set of variables
Comments: To: "N. Knese" <n.knese@GMX.DE>
In-Reply-To:  <200708291019.l7T2b2FK024423@malibu.cc.uga.edu>
Content-Type: text/plain; charset="us-ascii"; format=flowed

At 06:19 AM 8/29/2007, N. Knese wrote:

>I have got a set of variables with different numbers of categories and >I >would like to find out all combinations of these variables/categories. > >Example: >var1: 1="a" 2="b" 3="c" >var2: 1="x" 2="y" >var3: 1="z" 2=m" > >-> var12: 11="ax" 12="ay" 21="bx" 22="by" 31="cx" 32="cy" >-> var13: 11="az" 21="bz" 31="cz" >-> var23: 11="xz" 21="yz" >-> var123:111="..." 211="..." 311 121 221 321 112 122 212 312 222 322

I'm not sure what you want. Do you want all these in one record (SPSS 'case'), or spread across multiple records? Usually the latter ('long' organization) is preferable, but you may have a reason for 'wide'.

You do list 6 values for 'var12', which requires at least 6 records - a variable can't have more than one value in a record.

Can you list a few *records* in your desired output? Or if you're thinking of one record only, can you tell us what you mean by

>-> var12: 11="ax" 12="ay" 21="bx" 22="by" 31="cx" 32="cy"

While I think of it: Is 'var12' a numeric or a string variable? It looks like it's numeric with value labels ("ax" being the value for numeric 11), but is that what you mean? (If it is, it'll be kind of complex code to generate it.)

So, give us what more information you can. I hope these questions help clarify what we need.

-Good luck, Richard


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