Following is a response from DHS staff member, Tom Pullum:
You can calculate the number of siblings with these lines (in Stata), before reshaping the IR file:
use "C:\Users\26216\ICF\Analysis - Shared Resources\Data\DHSdata\NGIR7BFL.DTA", clear
rename *_0* *_*
* Calculate the number of siblings each woman has
gen nsibs=0
forvalues lsibs=1/20 {
replace nsibs=nsibs+1 if mm1_`lsibs'<.
}
tab nsibs
tab nsibs [iweight=v005/1000000]
summarize nsibs [iweight=v005/1000000]
The weighted mean is 5.23 siblings. Note that you have to allow for the possibility of 0 siblings. This can be modified to give the number of siblings who are males, females, still alive, etc. I am repeating the Stata lines I gave earlier, because what I pasted the first time omitted m7. The full program is below--but it does not include the lines to calculate the adult and maternal mortality rates. Those lines are on our GitHub site.
use "C:\Users\26216\ICF\Analysis - Shared Resources\Data\DHSdata\NGIR7BFL.DTA", clear
rename *_0* *_*
* Calculate the number of siblings each woman has
gen nsibs=0
forvalues lsibs=1/20 {
replace nsibs=nsibs+1 if mm1_`lsibs'<.
}
tab nsibs
tab nsibs [iweight=v005/1000000]
summarize nsibs [iweight=v005/1000000]
* For this example just keep mm1 and mm7 and mm9
keep v001 v002 v003 mm1_* mm7_* mm9_*
reshape long mm1_ mm7_ mm9_, i(v001 v002 v003) j(index)
rename *_ *
tab mm1, m
* Drop the lines that go beyond the woman's actual number of siblings
drop if mm1==.
tab mm9 if mm1==2 & mm7>=15 & mm7<=49,m