The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Data » Weighting data » Merging wealth index with individual file
Merging wealth index with individual file [message #8394] Thu, 22 October 2015 13:11 Go to next message
Saima is currently offline  Saima
Messages: 10
Registered: October 2015
Location: Bowling Green, Ohio
Member
Hello All,

I am trying to merge the wealth index with IR file for Pakistan Demographic Health Survey of 1990. In the wealth index Only whhid variable is available as a unique identifier. However, these identifiers do not match with caseid in IR file. Can someone please suggest me how to solve this problem.


Saima
Re: Merging wealth index with individual file [message #8405 is a reply to message #8394] Fri, 23 October 2015 18:01 Go to previous message
Reduced-For(u)m
Messages: 292
Registered: March 2013
Senior Member


From a previous post:

http://userforum.dhsprogram.com/index.php?t=msg&th=2075& amp;goto=4224&S=851fe28e75716e4e1e9654ca24639320#msg_422 4

*begin using the individual recode (I used child, but should still work)
use child.dta

*generate the variable that corresponds to the wealth data
gen whhid = substr(caseid, 1, 12)

*merge
merge m:1 whhid using wealth.dta
Previous Topic: Pooling DHS from same country
Next Topic: Setting svyset for KDHS 2008
Goto Forum:
  


Current Time: Fri Aug 12 11:53:42 Coordinated Universal Time 2022