I have a survey with two sample populations. One is representative of the general population (frequency 2029), one is representative of a specific target population (frequency 5934). I have to create very simple tabulations of variables that capture questions asked of BOTH the general and target populations. However, I have never done such tabulations including two different weights. Any advice on how I can integrate two different weights into one tabulate command?
Code:
. tab sample
Data Only Variable: |
Sample | Freq. Percent Cum.
--------------------+-----------------------------------
General Pop | 2,029 25.48 25.48
Target Pop | 5,934 74.52 100.00
--------------------+-----------------------------------
Total | 7,963 100.00Code:
. codebook weight_gp // for general pop analyses
---------------------------------------------------------------------------------------------
weight_gp Post-Stratification weight for Gen Pop (n=2,029)
---------------------------------------------------------------------------------------------
type: numeric (double)
range: [.212,3.052] units: .0001
unique values: 1,129 missing .: 5,934/7,963
mean: 1
std. dev: .328805
percentiles: 10% 25% 50% 75% 90%
.6517 .7857 .9459 1.1671 1.4248
. codebook weight_target // for target pop analyses
---------------------------------------------------------------------------------------------
weight_target Post-Stratification weight for Qualified Targeted Sample (n=5,934)
---------------------------------------------------------------------------------------------
type: numeric (double)
range: [.0655,7.6575] units: .0001
unique values: 1,647 missing .: 2,029/7,963
mean: 1
std. dev: 1.27466
percentiles: 10% 25% 50% 75% 90%
.1665 .293 .5625 1.1167 2.1893Code:
mleave_pew Following the birth or adoption of a child, do you think MOTHERS should be able
---------------------------------------------------------------------------------------------
type: numeric (byte)
label: Q14A
range: [1,99] units: 1
unique values: 3 missing .: 0/7,963
tabulation: Freq. Numeric Label
7,802 1 Yes, mothers should be able to
take leave
115 2 No, mothers should not be able
to take leave
46 99 Refused
* Example generated by -dataex-. To install: ssc install dataex
clear
input byte mleave_pew
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
2
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
end
label values mleave_pew Q14A
label def Q14A 1 "Yes, mothers should be able to take leave", modify
label def Q14A 2 "No, mothers should not be able to take leave", modify
0 Response to How do I insert two weights in one tabulate command?
Post a Comment