The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Topics » Nutrition and Anthropometry » replicating children 6-23 month
replicating children 6-23 month [message #14957] Mon, 21 May 2018 09:16 Go to previous message
Riri is currently offline  Riri
Messages: 1
Registered: May 2018
Location: Ethiopia
Member
Dear

I am using the Ethiopian 2016 DHS and I couldnt match the table 11.8 "among youngest children age 6-23 months living with the mother". The total number in the table includes 2960 children while I am getting 3075 after applying the following command in stata.

use "C:\Users\UserPc\Desktop\thesis\stata 2016\diet diet.dta" , clear
gen age = v008-b3

* select on the living children 6-23 month
keep if age<24 &age>5 & b5==1

* regroup age
recode age(0/5=.)(6/8=1 "6-8")(9/11=2 "9-11")(12/17=3 "12-17")(18/23=4 "18-23")(24/59=.), gen(child_age)


tab child_age
tab child_age[iw=v005/1000000]

* Keep only those living with their mother
keep if b9==0

* for checking if the child is the youngest
drop if _n > 0 & caseid == caseid[_n-1]

tab child_age
tab child_age[iw=v005/1000000]

Can you please explain to me how I can get the exact number and percentage as the table in the report.
Thank you
 
Read Message
Read Message
Read Message
Previous Topic: Conindex results not matching.
Next Topic: Calculation age
Goto Forum:
  


Current Time: Sun Dec 22 14:58:52 Coordinated Universal Time 2024