Hello everyone!
I have a simple question ; I want to "put in excel" weighted row proportions.
I was writing the following codes:
The problem is that the e(Prop) is giving me the weighted cell proportion and I am not being able to get the row proportion (e.g. 59% and not 10%).
Thank you!
I have a simple question ; I want to "put in excel" weighted row proportions.
I was writing the following codes:
Code:
svy: tab Outcome Covariate, row local Per=(e(Prop)[2,1]*100) local Per_s=string(`Per', "%9.1f") putexcel F4 = `"`Per_s'"' Outcome=BMI_catOb Covariate=gender ***************** . svy: tab BMI_catOb gender, row (running tabulate on estimation sample) Number of strata = 2 Number of obs = 2,465 Number of PSUs = 50 Population size = 158,768.93 Design df = 48 ---------------------------------- RECODE of | bmiz_cat | (BMI 5 | Child Gender cat) | Male Female Total ----------+----------------------- Non Obes | .4762 .5238 1 Obesity | .5977 .4023 1 | Total | .4972 .5028 1 ---------------------------------- Key: Row proportion Pearson: Uncorrected chi2(1) = 20.8483 Design-based F(1, 48) = 13.4654 P = 0.0006 . svy: tab BMI_catOb gender (running tabulate on estimation sample) Number of strata = 2 Number of obs = 2,465 Number of PSUs = 50 Population size = 158,768.93 Design df = 48 ---------------------------------- RECODE of | bmiz_cat | (BMI 5 | Child Gender cat) | Male Female Total ----------+----------------------- Non Obes | .3938 .4332 .8269 Obesity | .1035 .0696 .1731 | Total | .4972 .5028 1 ---------------------------------- Key: Cell proportion Pearson: Uncorrected chi2(1) = 20.8483 Design-based F(1, 48) = 13.4654 P = 0.0006
Thank you!
Comment