Hi there, hope some of you can help. I am using SPSS/PASW I have a merged my data set from a longitudinal investigation of 2000 users measured in 3 different times. 2008-2009 and 2010. Unfortunately there are several drop outs, some have answered only in 2008 and 2009, other in 2008 and 2010, and some all the three periodes. However how can I identify or only make use of the cases or individuals that have responded on all three times in the investigation? I have tried several different approaches in "Select cases" and "if condition is satisfied", but I only get strange samples. Can somebody help me? |
Administrator
|
When merging, did you add cases (via ADD FILES), or add variables/columns (via MATCH FILES)?
Re your desire to use only individuals who have data for all 3 time periods, have you considered using multilevel modeling (via MIXED)? It would not be bothered by the fact that people have varying numbers of time points to contribute. (It requires a LONG file structure, such that each individual has one row for each occasion of measurement.) The UCLA Computing website has syntax for many of the examples in Singer & Willett's book "Applied Longitudinal Data Analysis". HTH.
--
Bruce Weaver bweaver@lakeheadu.ca http://sites.google.com/a/lakeheadu.ca/bweaver/ "When all else fails, RTFM." PLEASE NOTE THE FOLLOWING: 1. My Hotmail account is not monitored regularly. To send me an e-mail, please use the address shown above. 2. The SPSSX Discussion forum on Nabble is no longer linked to the SPSSX-L listserv administered by UGA (https://listserv.uga.edu/). |
In reply to this post by PetterBB
PetterBB,
I'll assume that you have a variable that identifies whether a person was in a dataset so that when you put the three datasets together (match files) you have those three variables. Let them be in2008, in2009, and in2010 with values of 0=not in the dataset and 1=in the dataset. The selection command is Select if (in2008 eq 1 and in2009 eq 1 and in2010 eq 1). If you don't have those three variables, one way to create them is by means of the IN subcommand of the match files command. Gene Maguin -----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of PetterBB Sent: Tuesday, November 30, 2010 10:25 PM To: [hidden email] Subject: Remove cases in SPSS/PASW Hi there, hope some of you can help. I am using SPSS/PASW I have a merged my data set from a longitudinal investigation of 2000 users measured in 3 different times. 2008-2009 and 2010. Unfortunately there are several drop outs, some have answered only in 2008 and 2009, other in 2008 and 2010, and some all the three periodes. However how can I identify or only make use of the cases or individuals that have responded on all three times in the investigation? I have tried several different approaches in "Select cases" and "if condition is satisfied", but I only get strange samples. Can somebody help me? -- View this message in context: http://spssx-discussion.1045642.n5.nabble.com/Remove-cases-in-SPSS-PASW-tp32 87151p3287151.html Sent from the SPSSX Discussion mailing list archive at Nabble.com. ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
In reply to this post by PetterBB
At 10:24 PM 11/30/2010, PetterBB wrote:
>I have a merged data set from a longitudinal investigation of 2000 >users measured in 3 different times, 2008-2009 and 2010. Some have >answered only in 2008 and 2009, other in 2008 and 2010, and some all >the three periods. > >However how can I identify or only make use of the cases or >individuals that have responded on all three times in the investigation? Is your problem solved? If not, here are the key points: a. As Gene Maguin wrote, make sure you have variables like in2008, in2009, and in2010, marking which year or years each case has data from. Much the easiest way to do this is with "/IN=" clauses on your ADD FILES or MATCH FILES statements. If you've already done the merge (ADD FILES or MATCH FILES) without "/IN=" clauses, ideally re-do it with those clauses. If that isn't possible, post how you data is structured; probably something can be worked out. b. After that, it depends whether your merged data is in 'long' form, with one record for each year for each user; or 'wide' form, with one record for each user and data for all years in the same record. (ADD FILES gives long form, MATCH FILES gives wide form.) If you have wide-form data, then (untested) COMPUTE All3yrs = in2008 AND in2009 AND in2010. If you have long-form-data, then (also untested, and assuming 'UserID' is a key variable identifying users) AGGREGATE OUTFILE=* MODE=ADDVARIABLES /BREAK=UserID /Has2008 = MAX(in2008) /Has2009 = MAX(in2009) /Has2010 = MAX(in2010). COMPUTE All3yrs = Has2008 AND Has2009 AND Has2010. c. Finally, to analyze only users with data for all three years, either FILTER BY All3yrs. or SELECT IF All3yrs. (Remember that "SELECT IF" permanently deletes cases. If you use it, make sure you also have a master file that retains all the data.) ===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD |
You can always use
temp .
before each select if command.
This applies to the next procedure only, after which the data reverts to the original . Even with this you should
have at least one backup copy of the original *.sav file, preferably on a CD or
remote server. See my tutorial http://surveyresearch.weebly.com/uploads/2/9/9/8/2998485/2.3.1.1__data_transformations.doc
|
Free forum by Nabble | Edit this page |