The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Data » Dataset use in Stata » weighting for Services Provision Assessment data
weighting for Services Provision Assessment data [message #10257] Thu, 14 July 2016 00:10 Go to next message
gizachew is currently offline  gizachew
Messages: 18
Registered: December 2015
Location: Australia
Member
Dear Survey experts
Greetings,

Thanks so much for the unceasing assistance so far. In my current analysis of Ethiopian SPA data, I am planning to conduct multilevel logistic regression analysis to identify determinants for client satisfaction in family planning services. For this, I do have client level factors (Level 1) and facility level factors (level2). Although I have generated the svyset using the following command (see below), I am not sure if I could apply this svy command in my commands for mixed regressions analysis (xtmelogit). Please suggest me if there are other alternatives

egen strata=group(FTYPE REGION)
svyset FACIL [pw=cliwt], strata(strata) singleunit(centered)

Gizachew
Re: weighting for Services Provision Assessment data [message #10486 is a reply to message #10257] Thu, 28 July 2016 21:00 Go to previous messageGo to next message
gizachew is currently offline  gizachew
Messages: 18
Registered: December 2015
Location: Australia
Member
Dear DHS Specialists,

I would like to include additional concerns. It seems the svyset is working with Melogit command. However, it is not possible for me to calculate the Intra class correlation(ICC) and akaike information criterion (AIC) using estat icc and estat aic, respectively in my STATA 14 packages. Would you please assist

best
Re: weighting for Services Provision Assessment data [message #10512 is a reply to message #10486] Mon, 01 August 2016 09:35 Go to previous messageGo to next message
Bridgette-DHS is currently offline  Bridgette-DHS
Messages: 3064
Registered: February 2013
Senior Member
Following is a response from DHS Stata Specialist, Shireen Assaf:

In order to use the svy command with a mixed model, you need to supply weights for each level. See the example in the Stata 14 Multilevel Mixed Effect manual page 83 for how this can be done when there are two weights: http://www.stata.com/manuals14/me.pdf. You need to have Stata version 14 to be able to do this.

I tried this using Senegal SPA as an example. First you need to merge the facility and FP files. Then follow the following steps:

*create the client and facility weights
gen clwt= clientwt/1000000
gen fcwt= facwt/1000000

*create the strata variable
egen strata=group(ftype region)

*svyset for mixed models using two weights
svyset facil, weight(fcwt) strata(strata) singleunit(centered) || _n, weight(clwt)

*client satisfaction outcome
recode x208 (1 = 1 "very satisfied") (2/3 =0 "more/less/not satisfied"), g(fpsat)

*client's age as an example
recode x302 (98=.), gen(age)

*this is a mixed model with random intercepts for facilities
svy: melogit fpsat age i.factype || facil:

*if you want to fit a model with random intercepts for facilities and clients you could fit the following model (this takes longer and looking at this example seems nothing changes)
svy: melogit fpsat age i.factype || facil: || clno:

I was not sure what type of mixed model you wanted to fit but this should give you an idea of how to proceed. For any more detail on using Stata with mixed models perhaps the Stata forum would help.

Re: weighting for Services Provision Assessment data [message #10520 is a reply to message #10512] Mon, 01 August 2016 22:26 Go to previous messageGo to next message
gizachew is currently offline  gizachew
Messages: 18
Registered: December 2015
Location: Australia
Member
Thanks so much Dr Assaf,

Yes, I did all the weighting for the facility and client and applied the svyset for the client vs facility merged data as my intention is to identify facility and client determinants of client satisfaction. In this regard, I created client satisfaction variable using polychoric pca for the 11 facets at X202 and then dichotomised into binary variable using the median as a cut point.
Now, your recommendation to include "singleunit(centered)" in the svyset helped me a lot.
1) However, I would remain grateful if you assist me on how to calculate Intraclass correlation coefficient (ICC) for the null model (empty model without covariates) and Akaike information criterion (AIC) for checking the model fitness. The estat icc and estat ic, respectively for ICC and AIC, recommended by the Stata manual 14 doesn't work for me.
2) I am also intended to create cluster level variable (facil is my cluster) by aggregating the individual client's response in each cluster/facil (1 -15 clients in the cluster). For this, I am using collapse command but not exactly sure for categorical variables. Do I need to include weighing during collapse?
For example, I created variables for "information on method use" and "privacy maintained" as follow yet not exactly sure which measure of centrality I have to use. I presume collapsing at mean or median could work for continuous variables such as waiting time and duration of consultation.

recode XF117_1 (8=.) (1=1 yes) (2=0 no), gen (metuse)
gen privmaintained=.
replace privmaintained=0 if OF110!=" "
replace privmaintained=1 if strpos(OF110,"AB")>0
recode X201 (998=.), gen (waitingtime)
collapse (mean)metuse privmaintained (median) waitingtime, by(FACIL)

Thanks in Advance
Gizachew
Re: weighting for Services Provision Assessment data [message #10526 is a reply to message #10520] Tue, 02 August 2016 12:55 Go to previous messageGo to next message
Bridgette-DHS is currently offline  Bridgette-DHS
Messages: 3064
Registered: February 2013
Senior Member
Another response from Shireen Assaf:


You cannot produce an AIC when you use svy. You may consider fitting your mixed model with only the client weight and without svy, then you can use estat ic to find your best fit models. If you do this, you would need to state that clearly in your methodology.

You can use weights in the collapse command. However, for a dichotomous variable you will need to recode your collapsed variable to indicate for instance at least 50% of facilities provided privacy, or at least one, etc. Yes, collapsing a continuous variable also works but you need to decide whether to leave the collapsed variable as it is or recode it further. The waitingtime collapsed variable you created gives the median waiting time by facility which seems fine.

Since these are Stata questions and not DHS questions, you probably would get more help or different recommendations if you consult the Stata forum.

Re: weighting for Services Provision Assessment data [message #10544 is a reply to message #10526] Fri, 05 August 2016 00:13 Go to previous message
gizachew is currently offline  gizachew
Messages: 18
Registered: December 2015
Location: Australia
Member
Dear Assaf,

Thanks so much for the explanations
Previous Topic: Pooled Survey MeLogit Syntax Query
Next Topic: Svy command, r(2000) error message, NFHS-3 India
Goto Forum:
  


Current Time: Thu May 23 11:44:24 Coordinated Universal Time 2024