The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Data » Merging data files » Merging household and women's individual data Myanmar 2015-2016
Re: Merging household and women's individual data Myanmar 2015-2016 [message #21993 is a reply to message #21897] Thu, 14 January 2021 13:50 Go to previous messageGo to previous message
Bridgette-DHS is currently offline  Bridgette-DHS
Messages: 3167
Registered: February 2013
Senior Member
Following is a response from Senior DHS Specialist, Kerry MacQuarrie:

Dear Stephanie,
You have renamed and matched the cluster and household number appropriately. However, hv003 does not match with v003. The variable hv003 refers to the line number of the person who answered the household questionnaire, not the line number of all individual women. You don't need it. Try the following:

use "C:\Users\qlu4\Desktop\mdhs_hh.dta"
gen v001=hv001 //recode hh survey cluster number variable to match women's data set 
gen v002 = hv002 //recode hh survey household number variable to match women's data set 
keep v001 v002 sh148 sh148f sh149 sh150 sh151 sh152 sh153 sh154 sh155 sh156 sh157 sh158 sh159 sh160 sh161 //keep only relevant variables
sort v001 v002 
save "C:\Users\qlu4\Desktop\mdhs_hh.dta", replace

use "C:\Users\qlu4\Desktop\mdhs_women.dta" 
sort v001 v002 
merge 1:m v001 v002 using "C:\Users\qlu4\Desktop\mdhs_hh.dta"  

In the Myanmar DHS, this matches 12,885 cases and leaves 3,095 cases in the HR file unmatched (ie households that did not have a corresponding eligible woman in the IR file)

/index.php?t=getfile&id=1660&private=0

  • Attachment: mrg.png
    (Size: 10.33KB, Downloaded 801 times)
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Merge PR and KR in wave 3, b16 does not exist
Next Topic: MERGING HIV DATASETS AND WOMEN DATASETS, DHS 2016-2017, HAITI.
Goto Forum:
  


Current Time: Sat Oct 5 18:28:58 Coordinated Universal Time 2024