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 (November 2006)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Wed, 1 Nov 2006 16:22:34 -0600
Reply-To:   "Peck, Jon" <>
Sender:   "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:   "Peck, Jon" <>
Subject:   Re: "raking" syntax
Comments:   To:
In-Reply-To:   A<>
Content-Type:   text/plain; charset="UTF-8"

The Bonus Pack, which was sent to early adopters of SPSS 15, contains a Python implementation of a raking procedure in the new module It fits a main-effects log linear model and calculates weights accordingly after various adjustments.

The Bonus Pack modules, which require SPSS 15, will be generally available on SPSS Developer Central next week. The raking module in particular requires the SPSS Advanced Models option because it uses GENLOG as part of its calculations.

Here is an example of using it for a two-dimensional model. In the example, there are proportions for values 0 and 1 of variables x and y, and the new variable finalwt is calculated. begin program. import spss, spssaux, rake


rake.rake(['x', 'y'], [{0:50, 1: 25}, {0:40, 1:35}], 'finalwt') end program.

HTH, Jon Peck

-----Original Message----- From: SPSSX(r) Discussion [mailto:SPSSX-L@LISTSERV.UGA.EDU] On Behalf Of leora lawton Sent: Wednesday, November 01, 2006 10:47 AM To: SPSSX-L@LISTSERV.UGA.EDU Subject: [SPSSX-L] "raking" syntax

Does anyone have syntax for 'raking' or something known as multiway post-stratification? I have a SAS* macro but I really could use it in spss.

thanks leora

* A SAS Macro for Balancing a Weighted Sample

Dr. Leora Lawton TechSociety Research "Custom Social Science and Consumer Behavior Research" 2342 Shattuck Avenue PMB 362, Berkeley, CA 94704 (510) 548-6174; fax (510) 548-6175; cell (510) 928-7572

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