************************************************************** **Syntax producing the USA heritage time use files 1975-1976** **written by Dr. Kimberly Fisher, Institute for Social and ** **Economic Research University of Essex, Wivenhoe Park ** **Colchester, United Kingdom, weighting section written by ** **Professor Jonathan Gershuny, ISER, Univ of Essex ** **11 April 2007, updated 20 May 2010 ** **************************************************************. *********************************************** *Part 3 - compile response supplementary file * ***********************************************. get file='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\AHTUS final files\Harmonised files\Questionnaire\USA75_76quest.sav' /keep survey wave hhid civstat. select if survey=2. execute. vector haspart(4). Loop i=1 to 4. compute haspart(i)=0. if civstat=1 and wave=i haspart(i)=1. if civstat=-8 and wave=i haspart(i)=-8. end loop. val lab haspart1 to haspart4 -8 missing 0 no partner this wave 1 yes. cro civstat by haspart1 haspart2 haspart3 haspart4. AGGREGATE /OUTFILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\aggr.sav' /BREAK=hhid /haspart1 'has partner wave 1' = MAX(haspart1) /haspart2 'has partner wave 2' = MAX(haspart2) /haspart3 'has partner wave 3' = MAX(haspart3) /haspart4 'has partner wave 4' = MAX(haspart4). ADD FILES /FILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\agmain.sav' /FILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\agspouse.sav'. EXECUTE. recode spouse (sysmis=0). var lab spouse marker of spouses. val lab spouse 0 main respondent 1 spouse. freq spouse. sort cases by hhid pid. match files files=* table='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\aggr.sav' /BY hhid. execute. val lab particp1 to particp4 -7 not relevant 0 non-respondent 1 participated. If spouse=1 and haspart1=0 and particp1=0 particp1=-7. If spouse=1 and haspart2=0 and particp2=0 particp2=-7. If spouse=1 and haspart3=0 and particp3=0 particp3=-7. If spouse=1 and haspart4=0 and particp4=0 particp4=-7. recode particp3 particp4 (-1=0). freq particp1 particp2 particp3 particp4. cro spouse by particp2 particp3 particp4. save outfile='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USA75response.sav' /drop haspart1 haspart2 haspart3 haspart4. *look at response patterns. recode goodr1 goodr2 goodr3 goodr4 (-1=2). compute respatrn= goodr1*1000 + goodr2*100 + goodr3*10 + goodr4. freq respatrn. *************************************************** *1218 (50.6%) returned a good diary all 4 waves * *drop out after a while * 139 (5.8%) good diaries waves 1-3, then out * 214 (8.9%) good diaries waves 1-2, then out * 578 (24.0%) good diary wave 1, then out * 89.4% up to this point * *not participate in wave 1, join later (mostly spouses) * 7 (0.3%) good diaries waves 2-4 * 2 (0.1%) good diaries waves 3-4 * 3 (0.1%) good diary wave 4 only * 89.8% up to this point * * 30 (1.2%) no good diaries * 91.0% up to this point * *the rest have intermittent response * 3 (0.1%) in W2 only * 1 (0.1%) in W2 and W4, not W1 or W3 * 5 (0.2%) in W2 and W3, not W1 or W4 * 14 (0.6%) in W1 and W4, not W2 or W3 * 23 (1.0%) in W1 and W3, not W2 or W4 * 79 (3.3%) in W1, W3 & W4, not W2 * 90 (3.7%) in W1, W2 & W4, not W3 *2406 total row cases ***************************************************. get file='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USA75response.sav'. SAVE OUTFILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\AHTUS final files\Harmonised files\Supplementary files\1975-76\USA75response.sav'. add files file='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\addwght75main.sav' /in=mf file='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\addwght75spouse.sav' /in=sf. execute. means pid by v7976 /cells=min max median. aggregate outfile=* mode=addvariables /break hhid /couple=max(sf). cro couple by mf sf. val lab couple 0 not in couple 1 in couple. cro v7976 by couple. *mostly the cases of couples have a v7976 value of 1 and *people not in couples have a v7976 value of 2, but there *are a few exceptions. compute origmo = v7972*v7973. if pid>1999 origmo=0. compute origmsp = v7972*v7973*v7976. var lab origmo original weight main respondent only. var lab origmsp original weight main and spouse respondents. Do if pid>1999. compute sex=sexsp. compute age=agesp. compute empstat=empstsp. End if. temp. select if pid<1999. freq sex. freq age. *15 missing age cases. temp. select if age=17. freq pid. *while the sample selection was for people aged 18+ though *also the spouse if the sampled person had a spouse, there *are 4 spouses aged 17. *create an age-sex distribution variable from which to *balance the distribution of days of the week by the *CPS distribution. recode age (17 thru 24=1)(25 thru 34=2)(35 thru 44=3) (45 thru 54=4)(55 thru 64=5)(65 thru hi=6) (else=8) into agegp. compute agesexgp=agegp+ 10*(sex-1). val lab agesexgp 1 "men 17 thru 24" 2 "men 25 thru 34" 3 "men 35 thru 44" 4 "men 45 thru 54" 5 "men 55 thru 64" 6 "men 65+" 8 "men age missing or bad diary" 11 "women 17 thru 24" 12 "women 25 thru 34" 13 "women 35 thru 44" 14 "women 45 thru 54" 15 "women 55 thru 64" 16 "women 65+" 18 "women age missing or bad diary" -82 missing age and sex. missing values agesexgp (8, 18, -82). freq agesexgp. freq sex. weight by origmsp. freq sex. weight by origmo. freq sex. weight off. aggregate outfile=* mode=addvariables /break tottime /summspwt=sum(origmsp) /summowt=sum(origmo). freq summspwt summowt. *both weights are inflated to the national population size. *inflation factor main respondents only - 10120.654 *inflation factor of main and spouse respondents - 13073.53. compute mowt=origmo/(summowt/4584). compute mspwt=origmsp/(summspwt/7088). weight by mowt. freq agesexgp diaryday. weight by mspwt. freq agesexgp diaryday. weight off. *the original weights do not balance the days of the week. *the original weights combine the CPS/Census demographic *adjustments and the sample attrition / nonresponse. *see notes in the original documentation on the variables used. *adjust the weights to retain the sex / age distributions *for each wave for the producers of good diaries. Make *1519 main respondents sampled, up to 4 waves, *the main respondents produced 4584 diaries. weight by mowt. temp. select if pid<1999. freq agesexgp. temp. select if lowqual=0 and baddem=0 and pid<1999. freq agesexgp. weight off. ****************************************** * Good cases Weighted * *men 18 thru 24 321 7.2% 7.2% 331* *men 25 thru 34 488 10.9% 10.7% 491* *men 35 thru 44 367 8.2% 8.3% 380* *men 45 thru 54 251 5.6% 5.6% 258* *men 55 thru 64 279 6.2% 6.4% 292* *men 65+ 368 8.2% 8.4% 383* *women 18 thru 24 344 7.1% 7.6% 350* *women 25 thru 34 510 15.2% 11.3% 518* *women 35 thru 44 346 8.1% 7.8% 359* *women 45 thru 54 396 8.5% 8.7% 399* *women 55 thru 64 359 7.8% 8.1% 371* *women 65+ 438 10.6% 9.9% 453* *Total 4467 4584* ******************************************. compute mainwt=0. if lowqual=0 and baddem=0 and pid<1999 and agesexgp=1 mainwt=mowt*(331/321). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=2 mainwt=mowt*(491/488). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=3 mainwt=mowt*(380/367). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=4 mainwt=mowt*(258/251). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=5 mainwt=mowt*(292/279). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=6 mainwt=mowt*(383/368). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=11 mainwt=mowt*(350/344). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=12 mainwt=mowt*(517/510). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=13 mainwt=mowt*(359/346). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=14 mainwt=mowt*(399/396). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=15 mainwt=mowt*(371/359). if lowqual=0 and baddem=0 and pid<1999 and agesexgp=16 mainwt=mowt*(453/438). weight by mainwt. freq agesexgp. weight off. *7088 diaries from main respondents and spouses. The original weight that *allows analysis of the spouses and the main respondents weights the people *who are not in couples as 2 people. weight by mspwt. freq agesexgp. temp. select if lowqual=0 and baddem=0. freq agesexgp. weight off. ****************************************** * Good cases Weighted * *men 18 thru 24 424 6.1% 6.1% 437* *men 25 thru 34 708 10.3% 10.1% 714* *men 35 thru 44 574 8.3% 8.4% 595* *men 45 thru 54 451 6.5% 6.5% 462* *men 55 thru 64 413 6.0% 6.1% 430* *men 65+ 528 7.6% 7.8% 557* *women 18 thru 24 551 8.0% 8.0% 566* *women 25 thru 34 868 12.6% 12.4% 878* *women 35 thru 44 546 7.9% 8.0% 566* *women 45 thru 54 621 9.0% 8.9% 629* *women 55 thru 64 563 8.2% 8.2% 579* *women 65+ 655 9.5% 9.5% 675* *Total 6902 7088* ******************************************. compute allwt=0. if lowqual=0 and baddem=0 and agesexgp=1 allwt=mspwt*(437/424). if lowqual=0 and baddem=0 and agesexgp=2 allwt=mspwt*(714/708). if lowqual=0 and baddem=0 and agesexgp=3 allwt=mspwt*(595/574). if lowqual=0 and baddem=0 and agesexgp=4 allwt=mspwt*(462/451). if lowqual=0 and baddem=0 and agesexgp=5 allwt=mspwt*(430/413). if lowqual=0 and baddem=0 and agesexgp=6 allwt=mspwt*(557/528). if lowqual=0 and baddem=0 and agesexgp=11 allwt=mspwt*(566/551). if lowqual=0 and baddem=0 and agesexgp=12 allwt=mspwt*(878/868). if lowqual=0 and baddem=0 and agesexgp=13 allwt=mspwt*(566/546). if lowqual=0 and baddem=0 and agesexgp=14 allwt=mspwt*(629/621). if lowqual=0 and baddem=0 and agesexgp=15 allwt=mspwt*(579/563). if lowqual=0 and baddem=0 and agesexgp=16 allwt=mspwt*(675/655). weight by allwt. freq agesexgp. weight off. *weight for main respondents and spouses to analyse couples where *both partners returned a good diary. 4574 diaries in such pairs. compute good=0. if lowqual=0 and baddem=0 good=1. aggregate outfile=* mode=addvariables /break wave hhid /ngood=SUM(good). freq ngood. weight by mspwt. temp. select if couple=1. freq agesexgp. temp. select if couple=1 and ngood=2. freq agesexgp. weight off. ****************************************** * Good cases Weighted * *men 18 thru 24 139 3.5% 3.3% 152* *men 25 thru 34 520 13.1% 12.1% 556* *men 35 thru 44 451 11.4% 10.6% 486* *men 45 thru 54 351 8.9% 8.5% 389* *men 55 thru 64 280 7.1% 7.1% 323* *men 65+ 356 9.0% 9.0% 414* *women 18 thru 24 240 6.1% 8.0% 272* *women 25 thru 34 510 12.9% 12.4% 594* *women 35 thru 44 351 8.9% 8.0% 407* *women 45 thru 54 346 8.7% 8.9% 425* *women 55 thru 64 229 5.8% 8.2% 307* *women 65+ 189 4.8% 9.5% 248* *Total 3963 4574* ******************************************. compute coupwt=0. if couple=1 and ngood=2 and agesexgp=1 coupwt=mspwt*(152/139). if couple=1 and ngood=2 and agesexgp=2 coupwt=mspwt*(556/520). if couple=1 and ngood=2 and agesexgp=3 coupwt=mspwt*(486/451). if couple=1 and ngood=2 and agesexgp=4 coupwt=mspwt*(389/351). if couple=1 and ngood=2 and agesexgp=5 coupwt=mspwt*(323/280). if couple=1 and ngood=2 and agesexgp=6 coupwt=mspwt*(414/356). if couple=1 and ngood=2 and agesexgp=11 coupwt=mspwt*(272/240). if couple=1 and ngood=2 and agesexgp=12 coupwt=mspwt*(594/510). if couple=1 and ngood=2 and agesexgp=13 coupwt=mspwt*(407/351). if couple=1 and ngood=2 and agesexgp=14 coupwt=mspwt*(425/346). if couple=1 and ngood=2 and agesexgp=15 coupwt=mspwt*(307/229). if couple=1 and ngood=2 and agesexgp=16 coupwt=mspwt*(248/189). weight by coupwt. freq agesexgp. weight off. aggregate outfile=* mode=addvariables /break tottime /summain=sum(mainwt) /sumall=sum(allwt). compute minfwt=mainwt*(summowt/summain). compute mspinfwt=allwt*(summspwt/sumall). var lab minfwt main respondent inflation weight. var lab mspinfwt main and spouse respondent inflation weight. format mainwt minfwt allwt mspinfwt coupwt (F8.4). desc allwt coupwt origmsp mspinfwt. weight by origmsp. freq agesexgp. weight by mspinfwt. freq agesexgp. weight off. sort cases by wave hhid pid. save outfile='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\wspwt.sav' /keep wave hhid pid agesexgp allwt mspinfwt coupwt origmsp. select if pid<2000. sort cases by wave hhid pid. save outfile='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\popwghts.sav' /keep wave hhid pid agesexgp mainwt minfwt origmo. ********************************************************************************************** *previous weight code from an older version of the AHTUS. This is kept as a historical record* **********************************************************************************************. GET FILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USWT75.SAV'. sort cases by wave hhid. rename variables (agsxsmwt daywt=agsxsmwa daywta). save outfile='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USWT75m.SAV' /keep wave hhid agsxsmwa daywta. GET FILE='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USWT75PLUS.SAV'. sort cases by wave hhid sex. match files files=* table='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USWT75m.SAV' /by wave hhid. execute. var lab agsxsmwa dem weight main only. var lab daywta day weight main only. var lab agsxsmwt dem weight with spouses. var lab daywt day weight with spouses. *as the daywt incorporates the demographic weight, *only the day weight will be added to the final files. sort cases by wave hhid sex. save outfile='C:\Users\Kimberly Fisher\Documents\Kimberly\time\ATUS\1975\USWT75m.SAV' /Keep wave hhid sex daywt daywta. recode daywt (sysmis=0). compute origwght = daywt. If hhid=877 and wave=1 origwght=1.44. If hhid=877 and wave=2 origwght=.58. If hhid=877 and wave=3 origwght=.58. If hhid=877 and wave=4 origwght=1.36. If hhid=1166 and wave=1 origwght=1.32. If hhid=1166 and wave=2 origwght=.7. If hhid=1166 and wave=3 origwght=.64. If hhid=1166 and wave=4 origwght=1.50. compute omaino = daywta. var lab omaino "for main resp only - CPS day/samp (exclude spouses)". If hhid=877 and wave=1 omaino=1.35. If hhid=877 and wave=2 omaino=.50. If hhid=877 and wave=3 omaino=.50. If hhid=877 and wave=4 omaino=1.12. If hhid=1166 and wave=1 omaino=1.2. If hhid=1166 and wave=2 omaino=.66. If hhid=1166 and wave=3 omaino=.62. If hhid=1166 and wave=4 omaino=1.51. **************************************************** **old version of weighting program used written by** **Professor Jonathan Gershuny ** ****************************************************. ********************************* *** STEP 1: *** *** Assemble sampling weights *** *********************************. *************************************************** *** 1.1 use attrition weights from make75_3.sps *** *** (also need N of adults in HH) *** ***************************************************. get file= "c:\f\usa\1975\q75harm2.sav". compute nadults= anhhu- anl18hu. sel if nadults gt 0. des anfamu anhhu anl18hu nadults. save out= "c:\f\usa\atus march 2005\atrwghts.sav" /keep= id nadults bwt cwt dwt /rename=(id=hhid). GET FILE "c:\f\usa\atus march 2005\atrwghts.sav". fre wave. compute attrwt=1. compute wave=1. save out= "c:\f\usa\atus march 2005\wave1.tmp" /keep hhid wave nadults attrwt. compute wave=2. save out= "c:\f\usa\atus march 2005\wave2.tmp" /keep hhid wave nadults bwt /rename bwt=attrwt. compute wave=3. save out= "c:\f\usa\atus march 2005\wave3.tmp" /keep hhid wave nadults cwt /rename cwt=attrwt. compute wave=4. save out= "c:\f\usa\atus march 2005\wave4.tmp" /keep hhid wave nadults dwt /rename dwt=attrwt. GET FILE='C:\F\USA\ATUS March 2005\addwght75main.sav'. sort cases by wave hhid. match files /file=* /file="c:\f\usa\atus march 2005\wave1.tmp" /in=w1in /file="c:\f\usa\atus march 2005\wave2.tmp" /in=w2in /file="c:\f\usa\atus march 2005\wave3.tmp" /in=w3in /file="c:\f\usa\atus march 2005\wave4.tmp" /in=w4in /by wave hhid. means attrwt by wave. sel if year gt 0. save out="temp.tmp". get file= "c:\f\usa\atus march 2005\addwght75spouse.sav" /rename=(sexsp agesp empstsp=sex age empstat). sort cases by wave hhid. match files /file=* /file="c:\f\usa\atus march 2005\wave1.tmp" /in=w1in /file="c:\f\usa\atus march 2005\wave2.tmp" /in=w2in /file="c:\f\usa\atus march 2005\wave3.tmp" /in=w3in /file="c:\f\usa\atus march 2005\wave4.tmp" /in=w4in /by wave hhid. sel if year gt 0. compute spopres=1. save out="temp2.tmp". save out="temp3.tmp" /keep=wave hhid spopres. match files file="temp.tmp" /file="temp3.tmp" /by wave hhid. sel if year gt 0. add files /file=* /file="temp2.tmp". recode spopres (sysmis=0). fre spopres. ******************************************************************** *** 1.2 fix for diary cases with missing vars in attrition model *** ********************************************************************. means attrwt by wave. if (missing(attrwt))attrwt=1. means attrwt by wave. ***************************************************** before fix after fix mean N mean N For Entire Population 1.0000 6967 1.0000 7088 1 first wave or only w 1.0000 2373 1.0000 2396 2 2nd wave 1.0046 1705 1.0045 1745 3 3rd wave .9968 1478 .9969 1511 4 4th wave .9979 1411 .9979 1436 *****************************************************. *************************************************** ***1.3 adjust attrition weights to share between*** ***partners and return to n=7088 *** ***************************************************. compute atwt=attrwt. if (spopres eq 1) atwt= attrwt/2. weight by atwt. fre year. **************************************** Label Frequency Percent Percent Percent 1975 1512 32.8 32.8 32.8 1976 3100 67.2 67.2 100.0 ------- ------- ------- Total 4612 100.0 100.0 *****************************************. weight off. compute atwt2=atwt* (7088/4612). ************************************************************* *** 1.4 adjust for selection probability within household *** *************************************************************. des nadults. compute wt = atwt2*(1/nadults). if sysmis(nadults)wt= atwt2*(1/1.92). means wt by wave. compute w=wt*(1/.6042). means w by wave. ***************************************************** before fix after fix mean N mean N For Entire Population .6029 7088 .9979 7088 1 first wave or only w .5852 2396 .9685 2396 2 2nd wave .6086 1745 1.0073 1745 3 3rd wave .6144 1511 1.0168 1511 4 4th wave .6135 1436 1.0155 1436 *******************************************************. des w. ****************************************** Variable Mean Std Dev Minimum Maximum W 1.00 .78 .00 5.91 7088 *******************************************. recode w (0=0)(else=1) into check. fre check. ****************************** Value Frequency Percent 0.00 26 .4 1.00 7062 99.6 *******************************. ********************************* *** STEP 2: *** *** ex post adjustment to CPS *** *** population parameters *** *********************************. **************************************************** * NOTE: * * CPS March Demographic proportions 1975 * * Men Women Men Women * * 18 to 24 18.1 17.2 8.4 9.2 * * 25 to 34 21.5 20.4 10.0 11.0 * * 35 to 44 16.0 15.4 7.4 8.3 * * 45 to 54 17.1 16.5 7.9 8.9 * * 55 to 64 13.6 13.9 6.3 7.5 * * 65 plus 13.6 16.6 6.3 8.9 * * ___________________________________ * * all 100 100 46.3 53.7 * ****************************************************. miss val age (-8). des age. *** note: 11 mising cases ***. recode age (18 thru 24=1)(25 thru 34=2)(35 thru 44=3) (45 thru 54=4)(55 thru 64=5)(5 thru hi=6) into agegp. compute agesexgp=agegp+ 10*(sex-1). val lab agesexgp 1 "men 18 thru 24" 2 "men 25 thru 34" 3 "men 35 thru 44" 4 "men 45 thru 54" 5 "men 55 thru 64" 6 "men 65 thru hi" 11 "women 18 thru 24" 12 "women 25 thru 34" 13 "women 35 thru 44" 14 "women 45 thru 54" 15 "women 55 thru 64" 16 "women 65 thru hi". fre agesexgp. weight by w. fre agesexgp. weight off. ******************************************************* * NOTE: * * Unweight Wtd by w % * * Value Label Frequency Percent Percent | CPS * * men 18 thru 24 312 4.4 4.2 | 8.4 * * men 25 thru 34 825 11.7 10.2 | 10.0 * * men 35 thru 44 636 9.0 7.1 | 7.4 * * men 45 thru 54 449 6.3 5.1 | 7.9 * * men 55 thru 64 404 5.7 5.0 | 6.3 * * men 65 thru hi 490 6.9 6.6 | 6.3 * * women 18 thru 24 485 6.9 6.7 | 9.2 * * women 25 thru 34 1078 15.2 15.5 |11.0 * * women 35 thru 44 670 9.5 8.2 | 8.3 * * women 45 thru 54 587 8.3 8.1 | 8.9 * * women 55 thru 64 508 7.2 9.6 | 7.5 * * women 65 thru hi 633 8.9 13.8 | 8.9 * * 11 Missing Missing | * * ------- ------- ------- | * * 7088 100.0 100.0 * * Valid cases 7077 Missing cases 11 * *******************************************************. compute agesexwt=-8. if agesexgp eq 1 agesexwt eq ( 8.4/ 4.2). if agesexgp eq 2 agesexwt eq (10.0/10.2). if agesexgp eq 3 agesexwt eq ( 7.4/ 7.1). if agesexgp eq 4 agesexwt eq ( 7.9/ 5.1). if agesexgp eq 5 agesexwt eq ( 6.3/ 5.0). if agesexgp eq 6 agesexwt eq ( 6.3/ 6.6). if agesexgp eq 11 agesexwt eq ( 9.2/ 6.7). if agesexgp eq 12 agesexwt eq (11.0/15.5). if agesexgp eq 13 agesexwt eq ( 8.3/ 8.2). if agesexgp eq 14 agesexwt eq ( 8.9/ 8.1). if agesexgp eq 15 agesexwt eq ( 7.5/ 9.6). if agesexgp eq 16 agesexwt eq ( 8.9/13.8). missing value agesexwt(-8). des agesexwt. ************************************************** Variable Mean Std Dev Minimum Maximum N AGESEXWT 1.04 .32 .64 2.00 7077 **************************************************. compute agsxsmwt=agesexwt*w. des agsxsmwt. *************************************************** Variable Mean Std Dev Minimum Maximum N AGSXSMWT 1.00 .81 .00 10.30 7077 ****************************************************. weight by agsxsmwt. fre agesexgp. weight off. ************************************************* NOTE: sample now corresponds to CPS distribution Label Value Frequency Percent men 18 thru 24 1.00 592 8.4 men 25 thru 34 2.00 706 10.0 men 35 thru 44 3.00 520 7.4 men 45 thru 54 4.00 553 7.8 men 55 thru 64 5.00 443 6.3 men 65 thru hi 6.00 448 6.3 women 18 thru 24 11.00 651 9.2 women 25 thru 34 12.00 777 11.0 women 35 thru 44 13.00 586 8.3 women 45 thru 54 14.00 628 8.9 women 55 thru 64 15.00 529 7.5 women 65 thru hi 16.00 628 8.9 ------- ------- Total 7061 100.0 Valid cases 4567 Missing cases 0 **************************************************. ********************************* *** STEP 3: *** *** adjust to produce same N *** *** of days for each age and *** *** sex group *** *********************************. miss val diaryday (-8). cro agesexgp by diaryday /cell=row. sel if (diaryday ge 1 and agesexgp gt 0). SAVE OUT='C:\F\USA\ATUS March 2005\WT75_2.TMP'. get file='C:\F\USA\ATUS March 2005\WT75_2.TMP'. ****************************************** *** 3.1 weight ignoring wave of survey *** ******************************************. sort cases by agesexgp diaryday. aggregate out='C:\F\USA\ATUS March 2005\group.TMP' /break=agesexgp /grouptot=sum(agsxsmwt) /groupn=nu. execute. aggregate out='C:\F\USA\ATUS March 2005\day.TMP' /break= agesexgp diaryday /daytot=sum(agsxsmwt) /dayn=nu. execute. match files file=* /table='C:\F\USA\ATUS March 2005\group.TMP' /by agesexgp. execute. match files file=* /table='C:\F\USA\ATUS March 2005\day.TMP' /by agesexgp diaryday. execute. compute exptot=(grouptot/7). compute daywt=(exptot/daytot)/(dayn/daytot). weight off. des daywt. ************************************************ NOTE: maximum weight 4.45 without any arbitrary truncation -- so this seems to have worked quite well! Variable Mean Std Dev Minimum Maximum N DAYWT 1.00 .54 .40 4.45 7067 *************************************************. weight by daywt. fre diaryday. cro agesexgp by diaryday /cell=row. **************************************** -- it balances the days of the week, Sunday Monday Tuesday Wednesda Thursday Friday Saturday Total men 18 thru 24 1 14.3 14.3 14.3 14.3 14.3 14.3 14.3 595 men 25 thru 34 2 14.3 14.3 14.3 14.3 14.3 14.3 14.3 707 men 35 thru 44 3 4.3 14.3 14.3 14.3 14.3 14.3 14.3 518 men 45 thru 54 4 14.3 14.3 14.3 14.3 14.3 14.3 14.3 553 men 55 thru 64 5 14.3 14.3 14.3 14.3 14.3 14.3 14.3 441 men 65 thru hi 6 14.3 14.3 14.3 14.3 14.3 14.3 14.3 448 women 18 thru 24 11 14.3 14.3 14.3 14.3 14.3 14.3 14.3 651 women 25 thru 34 12 14.3 14.3 14.3 14.3 14.3 14.3 14.3 777 women 35 thru 44 13 14.3 14.3 14.3 14.3 14.3 14.3 14.3 581 women 45 thru 54 14 14.3 14.3 14.3 14.3 14.3 14.3 14.3 630 women 55 thru 64 15 14.3 14.3 14.3 14.3 14.3 14.3 14.3 532 women 65 thru hi 16 14.3 14.3 14.3 14.3 14.3 14.3 14.3 630 Total 1009 1009 1009 1009 1009 1009 1009 7063 14.3 14.3 14.3 14.3 14.3 14.3 14.3 100.0 **************************************. fre agesexgp. ****************************************************** -- and it maintains the ex-post weighting! Value Label Frequency Percent Percent | CPS % men 18 thru 24 592 8.4 8.4 | 8.4 men 25 thru 34 706 10.0 10.0 | 10.0 men 35 thru 44 520 7.4 7.4 | 7.4 men 45 thru 54 553 7.8 7.8 | 7.9 men 55 thru 64 442 6.3 6.3 | 6.3 men 65 thru hi 447 6.3 6.3 | 6.3 women 18 thru 24 651 9.2 9.2 | 9.2 women 25 thru 34 777 11.0 11.0 | 11.0 women 35 thru 44 584 8.3 8.3 | 8.3 women 45 thru 54 628 8.9 8.9 | 8.9 women 55 thru 64 529 7.5 7.5 | 7.5 women 65 thru hi 628 8.9 8.9 | 8.9 ------- ------- ------- | 7057 100.0 100.0 | Valid cases 4565 Missing cases 0 ****************************************************** *************************************************** *** 3.2 alternative weight using wave of survey *** ***************************************************. weight off. sort cases by agesexgp wave diaryday. aggregate out='C:\F\USA\ATUS March 2005\group2.TMP' /break=agesexgp wave /grptot2=sum(agsxsmwt) /groupn=nu. execute. aggregate out='C:\F\USA\ATUS March 2005\day2.TMP' /break= agesexgp wave diaryday /daytot2=sum(agsxsmwt) /dayn2=nu. execute. match files file=* /table='C:\F\USA\ATUS March 2005\group2.TMP' /by agesexgp wave. execute. match files file=* /table='C:\F\USA\ATUS March 2005\day2.TMP' /by agesexgp wave diaryday. execute. compute exptot=(grptot2/7). compute daywt2=(exptot/daytot2)/(dayn2/daytot2). des daywt2. *************************************************** NOTE: large sd, very large extreme values reflecting seasonal imbalence of days-of-week -- so reject method for most purposes Variable Mean Std Dev Minimum Maximum N DAYWT2 1.00 1.16 .22 22.31 7067 ****************************************************. weight by daywt2. cro wave by diaryday /cell=row. ************************************************************** Does give seasonal weights, but only by assigning extreme weights to some cases (also the algorithm is failing slightly in some cases) Sunday Monday Tuesday Wednesda Thursday Friday Saturday Total first wave 1 14.3 14.3 14.3 14.3 14.3 14.3 14.3 2331 2nd wave 2 14.5 14.5 14.5 13.2 14.5 14.5 14.5 1729 3rd wave 3 14.3 14.3 14.3 14.3 14.3 14.3 14.3 1526 4th wave 4 14.3 14.3 14.3 14.3 14.3 14.3 14.3 1449 Column 1008 1008 1008 987 1008 1008 1008 7035 Total 14.3 14.3 14.3 14.0 14.3 14.3 14.3 100.0 ******************************************************************************. weight off. des t0pcare to tmiss. weight by daywt. des t0pcare to tmiss. weight by daywt2. des t0pcare to tmiss. ******************************************************************************* Respondents and partners unweighted_________| daywt_____________| daywt2____________ Variable Mean sd N | Mean sd N | Mean sd N T0PCARE personal care 658 148 7067 | 646 144 7057 | 645 142 7036 T1PAID paid work 166 240 7067 | 203 250 7057 | 210 252 7036 T2ED education 8 52 7067 | 11 61 7057 | 11 60 7036 T3UNPAID unpaid work 176 168 7067 | 169 168 7057 | 168 169 7036 T4ACVOL adult care etc 35 85 7067 | 30 80 7057 | 30 78 7036 T5OUTHM out of home 20 65 7067 | 17 58 7057 | 17 58 7036 T6EXERC exercise 32 77 7067 | 28 72 7057 | 27 69 7036 T7INHM in home 83 120 7067 | 76 113 7057 | 76 113 7036 T8MEDIA use media 185 153 7067 | 181 148 7057 | 178 148 7036 T9TRAV travelling 76 78 7067 | 76 77 7057 | 76 76 7036 TMISS (no main act) 2 32 7067 | 2 28 7057 | 2 25 7036 NOTE: Respondents only unweighted_________| daywt_____________| daywt2____________ Variable Mean sd N | Mean sd N | Mean sd N T0PCARE personal care 662 150 4567 | 647 143 4565 | 647 140 4506 T1PAID paid work 156 232 4567 | 197 246 4565 | 207 248 4506 T2ED education 9 56 4567 | 13 66 4565 | 11 62 4506 T3UNPAID unpaid work 173 166 4567 | 166 165 4565 | 164 165 4506 T4ACVOL adult care etc 35 82 4567 | 31 78 4565 | 30 75 4506 T5OUTHM out of home 22 69 4567 | 19 62 4565 | 19 62 4506 T6EXERC exercise 32 77 4567 | 28 72 4565 | 28 68 4506 T7INHM in home 86 123 4567 | 77 116 4565 | 77 115 4506 T8MEDIA use media 187 156 4567 | 182 151 4565 | 177 149 4506 T9TRAV travelling 77 79 4567 | 78 75 4565 | 78 76 4506 TMISS (no main act) 3 32 4567 | 2 29 4565 | 2 27 4506 *******************************************************************************. *********************************** *** JG's prelim conclusions: *** *** use daywt /not/ daywt2, but *** *** provide latter for use with *** *** appropriate health warnings *** ***********************************. weight off. sort cases by wave hhid. save out='C:\F\USA\ATUS March 2005\USwt75plus.sav' /keep = hhid, sex, wave, agsxsmwt, daywt, daywt2.