Dear Experts,
I want to obtain a cut-off for MUAC among infants less than 6 months of age.
These are my syntax, I am not sure about commands as I am new to this.
********first I have created a variable for death from birth to twelve months.
capture drop death_until_twelve
gen death_until_twelve=1 if dod_birth !=. | dod_three !=. | dod_six !=. | dod_nine !=. | dod_twelve !=.
replace death_until_twelve=0 if death_until_twelve==.
tab death_until_twelve
*******then I have grouped a variable for MUAC with categories mentioned below
capture drop muac2
gen muac2 = 0 if muacs>=12.5
replace muac2 = 1 if muacs<12.5 & muacs>=12.0
replace muac2 = 2 if muacs<12.0 & muacs>=11.5
replace muac2 = 3 if muacs<11.5 & muacs>=11.0
replace muac2 = 4 if muacs<11.0 & muacs>=10.5
replace muac2 = 5 if muacs<10.5 & muacs>=10.0
replace muac2 = 6 if muacs<10.0 & muacs>=9.5
replace muac2 = 7 if muacs<9.5 & muacs>=9.0
replace muac2 = 8 if muacs<9.0 & muacs>=8.5
replace muac2 = 9 if muacs<8.5 & muacs>=8.0
replace muac2 = 10 if muacs<8.0 & muacs>=7.5
replace muac2 = 11 if muacs<7.5 & muacs>=7.0
replace muac2 = 12 if muacs<7.0 & muacs>=6.5
replace muac2 = 13 if muacs<6.5
tab muac2
********Then, I run logit
logit death_until_twelve muac2
predict yhat, pr
roctab death_until_twelve yhat, detail
lsens
Please suggest the right way to get the results. Your help would be highly appreciated.
Thanks with sincere regards,
Harpreet
Related Posts with To determine a discriminatory value for MUAC for risk of mortality by 12 months
Can esttab produce percent change results for mixed models with log-transformed dependent variable?Hi Statalist, Is it possible to create a coefficients table that produces percent change instead of…
asdoc : addition of bysort prefix with tab, tab1, tab2 commandsI have just added support for the bysort prefix with tabulation commands in asdoc. Details and examp…
outreg2 after tab1Using the below code, I generate several one-way frequency tables. I would like to send all the tabl…
encode a string variable according to subsrtHi, I have a string variable, vq9_breakupdivorce, which has only 2 string values. Code: * Example …
multilevel ordinal probit model_meoprobit_iccI am intending to establish a multilevel ordinal probit model. The dependent variables is injury sev…
Subscribe to:
Post Comments (Atom)
0 Response to To determine a discriminatory value for MUAC for risk of mortality by 12 months
Post a Comment