If this is not successful or you need further assistance, please contact the IT Help Desk by calling 70.
If SPSS is currently open, you will need to close and re-open it for the license to take effect.
This product is not licensed for student use or faculty use on personal computers. This product is only licensed to be installed on Queens owned computers. *Restore integer ageĭelete vari parent youngage1 youngage2 youngage.Note: You do not have to be connected to the Queens network to download the setup file and perform this installation, however, the license activation process requires that you be connected to the Queens network at the time of activation. *and the age isn't integer, assign 1.Ĭompute age= rnd(age). If popnum=0 and momnum=0 /*if we deal with a parentĪnd ageyoungage /*and the youngage age listed is not their ownĪnd rnd(youngage)youngage kidhashealth= 1. *Remember that YOUNGAGE is not integer if that child has HASHEALTH=1. *Take the minimal value from the two passes.Ĭompute youngage= min(youngage1,youngage2). break= hhid parent /*breaking is done also by household, of course *youngest child, provided the man has children) to all cases of the group, *and so we can propagate the minimal age in that group (which is the age of the
*Now a father and his children have the same code in PARENT *and if the case is not a child, fill there PID.
Combine POPNUM and PID numbers in one column.Ĭompute parent= popnum. *In order to insert the info about health right into the age number. *Let's add small fractional noise to those children AGE who HASHEALTH=1. The use of syntax is very useful when doing data management. In many instances, you may find that using syntax is simpler and more convenient than using point-and-click. The code makes the assumption that AGE is integer. The purpose of this seminar is to help you learn about the use of SPSS syntax as an alternative to the point-and-click interface. So, no guarantees for all the data with their peculiarities. The code below was tested only on your small data snippet. Can anybody think of a way to accomplish what I'm trying to do, with syntax or otherwise?Įdited with sample data: HHID |PID |AGE |POPNUM |MOMNUM |HASHEALTH |KIDHASHEALTH
So far, I've been unable to figure out how to do this using SPSS syntax. Here's the problem: I need to set the KIDHASHEALTH value of any given parent to the HASHEALTH value of the youngest person whose HHID and POPNUM or MOMNUM value match the HHID and PID of the current case-functionally, their youngest child.
Everything seems pretty straightforward, except for one operation that's giving me trouble.įor each case in my dataset-each case representing an individual surveyed-the following (relevant) variables are defined: tracy the turtle codes After we import Turtle we can give commands like.
I've chosen SPSS to work with the data, because it seemed like the easiest piece of software to jump right into given my limited timeframe. For a school project, I've found myself playing with data from the Census Bureau's Current Population Survey.