The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Topics » Reproductive Health » Women having living children (NDHS 2016)
Re: Women having living children (NDHS 2016) [message #25601 is a reply to message #25592] Wed, 16 November 2022 09:09 Go to previous messageGo to previous message
Janet-DHS is currently offline  Janet-DHS
Messages: 893
Registered: April 2022
Senior Member
Following is a response from DHS staff member Tom Pullum:

The Stata code below will give you such a variable. However, the last category is "No living children" rather than "No live birth". This is necessary because the other categories describe living children. Note that the standard recode file does not include variables "living sons" or "living daughters". You have to get these by adding up sons and daughters who are living at home and living elsewhere.


use "...NGIR7BFL.DTA", clear

* Construct variables for living sons and living daughters
gen sons=v202+v204
gen dtrs=v203+v205

gen combination=3
replace combination=1 if sons>=1 & dtrs==0
replace combination=2 if sons==0 & dtrs>=1
replace combination=4 if sons==0 & dtrs==0

label variable combination "Living children"
label define combination 1 "Sons only" 2 "Daughters only" 3 "Mixed" 4 "No living children"
label values combination combination

tab combination [iweight=v005/1000000]
 
Read Message
Read Message
Read Message
Previous Topic: Code for Antenatal Care Tables in India DHS, 2019-21 - Final Report
Next Topic: What abortion questions are included in DHS surveys?
Goto Forum:
  


Current Time: Mon Dec 2 09:05:29 Coordinated Universal Time 2024