The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Countries » Uganda » Matching Domestic Violence Variable Data (Matching Domestic Violence data in report with dataset data)
Matching Domestic Violence Variable Data [message #28677] Wed, 21 February 2024 18:06 Go to next message
OSUMarina is currently offline  OSUMarina
Messages: 1
Registered: February 2024
I am trying to match the spousal violence data (table Table 18.8.1) in the Uganda 2006 report. In particular I am finding my calculations off for sexual spousal violence to what is in the table. I am using the following process in Stata:

*Generating DV weights
gen wgt = d005/1000000
svyset [pw=wgt], psu (v021) strata (v023)

*Selecting only women who participated in the DV module
drop if (v044 == 0 | v044 == 2 | v044 == 3)

*I am only interested in data from the Northern Region - so selected that data. Though I am also not able to match the data for the national level estimates if I skip this step (31 in my analysis versus 35.5 in the report).
keep if v024 == 6

*To get the sexual violence estimate I first used d108
replace d108 = . if d108 == 9
svy: tab d108

I get a prevalence rate of .1984 but the table (for North) says 27.1. The weighted denominators match what in the report (247) and equal women who are currently or formerly married (v502 == 1 or 2).

*To cross check I tried to recreate the sexual violence variables from the base variables
gen sex_2 = 0 if v502 != 0
replace sex_2 = 1 if d105i == 1 | d105i == 2 | d105j == 1 | d105j == 2
svy: tab sex_2

I got the same results (.1984).

I am wondering what I am doing wrong! Thank you for any advice.
Re: Matching Domestic Violence Variable Data [message #28884 is a reply to message #28677] Fri, 22 March 2024 09:50 Go to previous message
Janet-DHS is currently offline  Janet-DHS
Messages: 720
Registered: April 2022
Senior Member
Following is a response from DHS staff member, Tom Pullum:

We apologize for the three-week delay in this response.  It was necessary to go back to the original CSPro code that was used to construct the table.  You asked about table 18.8.1, but this depends on the construction of components of indicators given in table 18.7.1.  The challenge is to construct the third component of the sexual violence indicator, which depends on marital status.  Here is Stata code to match the sexual violence indicator in tables 18.7.1 and 18.7.2:

* Calculate the 3 components and the combined indicator for sexual violence
* Standard table for "Forms of spousal violence: Women" and  "Spousal violence
*   by background characteristics: Women", which only uses the combined indicator

* Illustrated with the Uganda 2006 survey, UG52
* Use codes 0/100 to get percentages with tabstat; for other purposes use 0/1

use "...UGIR52FL.DTA", clear

gen     v_sexualA=0
replace v_sexualA=100 if d105h>0 & d105h<9

gen     v_sexualB=0
replace v_sexualB=100 if d105i>0 & d105i<9

gen     v_forced=0
replace v_forced=100 if d123==2 | d124==1 | d125==1

gen     v_ini=0
replace v_ini=100 if v503==1 & d123==2 & (d127==1 | d127==2)

gen     v_sexualC=0
replace v_sexualC=100 if (v_forced==100 & v_ini==100)

gen     v_sexual=0
replace v_sexual=100 if v_sexualA==100 | v_sexualB==100 | v_sexualC==100

tabstat v_sexual*  if v502>0 [fweight=d005], statistics(mean) by(v024)
Previous Topic: Woman's Land Titel
Next Topic: A n Urgent Request: how to merge data files
Goto Forum:

Current Time: Mon May 27 11:48:50 Coordinated Universal Time 2024