The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Data » Weighting data » Adjusting survey weights in melogit in Stata
Adjusting survey weights in melogit in Stata [message #23634] Sat, 23 October 2021 11:25 Go to previous message
Asantie is currently offline  Asantie
Messages: 3
Registered: October 2021
Member
Hi DHSers,

I am currently using Ethiopian DHS 2016 data to examine predictors of institutional delivery

Based on IR data, I have created necessary dependent (outcome) and independent variables (varlist). In the analysis I would like to consider the complex survey design nature of DHS survey and used the following STATA code:



gen female_wgt= v005 /1000000


svyset v021 [pw=female_wgt], strata(v023)
svy: melogit outcome varlist if ANC_use==1 || v001:


But I received the following error message:

survey final weights not allowed with multilevel models;
a final weight variable was svyset using the [pw=exp] syntax, but multilevel models require
that each stage-level weight variable is svyset using the stage's corresponding weight()
option an error occurred when svy executed melogit"


I think the problem is with the code I used to specify "pw" or "weight" Could you please help me how I need to write the command for svyset and svy with proper weight code????


Many thanks in advance
Asantie

[Updated on: Sat, 23 October 2021 11:27]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Previous Topic: PSU and Uganda IR data
Next Topic: Create a variable using Percentage from cross tabulation
Goto Forum:
  


Current Time: Thu Apr 18 11:56:27 Coordinated Universal Time 2024