The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Countries » India » Creating an unbalanced panel
Re: Creating an unbalanced panel [message #18512 is a reply to message #18509] Wed, 11 December 2019 10:12 Go to previous messageGo to previous message
Niranjana is currently offline  Niranjana
Messages: 13
Registered: October 2019
Member
Thank you Tom and Bridgette.

I know that IR file contains all necessary information.

This is the code I used:



gen id =_n
sort v007 caseid
by year caseid: gen newid = 1 if _n==1
replace newid = sum(newid)
replace newid = . if missing(caseid)


duplicates report newid
rename b*_0* b*_*
keep caseid-v458
reshape long bidx_ bord_ b0_ b1_ b2_ b3_ b4_ b5_ b6_ b7_ b8_  b10_ b11_ b12_ b13_ b15_ b16_, i(newid) j(bindex)
drop if bidx==.

I was able to create a panel to analyse the impact of historical policies. Would this be right?
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Appending multiple waves of the NFHS annd PSU codes
Next Topic: NFHS III and IV comparability of slum and non-slum data among 8 major cities, India
Goto Forum:
  


Current Time: Sat Nov 23 15:40:45 Coordinated Universal Time 2024