The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Topics » Domestic Violence » Multilevel Weights
Re: Multilevel Weights [message #15354 is a reply to message #15332] Tue, 03 July 2018 23:04 Go to previous messageGo to previous message
Liz-DHS
Messages: 1516
Registered: February 2013
Senior Member
A response from Dr. Shireen Assaf:
Quote:


Dear user,

To be able to use multilevel modeling with DHS data and the svy command, a weight must be applied for each level. Since we only have one weight, we can make the assumption that all individuals in the household have the same weight. The Stata code to run a multilevel model for a binary outcome is below using the melogit command. However, you can use other mixed model commands if your outcome had a different distribution. The svyset should be the same.

gen wt=v005/1000000
gen wt2=1
svyset v001, weight(wt) strata(v023) , singleunit(centered) || _n, weight(wt2)

*this is a random intercept model
svy: melogit outcome var1 var2 || v001:

*random intercept and random slop for var3
svy: melogit outcome var1 var2 || v001: var3
*for this model you can also add the covariance(unstructured) option. Please read the stata documentation for the melogit command on this
* you can also check the Stata documentation for svyset, they discuss how to construct this for multistage sample design. 
Hope this helps.

Best,

Shireen Assaf
Technical Specialist
The DHS Program
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Disability and spousal violence [Nigeria DHS 2018]
Next Topic: Domestic violence
Goto Forum:
  


Current Time: Wed Apr 24 18:27:28 Coordinated Universal Time 2024