The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Countries » India » Issues with replicating STATcompiler results for India (Issues with replicating "justifies beating" results given in STATcompiler using the 2019-21 recode datasets for India.)
Issues with replicating STATcompiler results for India [message #28451] Tue, 09 January 2024 07:24 Go to next message
Navya is currently offline  Navya
Messages: 6
Registered: May 2022
Member
Dear all,

I am having some trouble replicating results from the DHS STATcompiler website for the wave 2019-21, specifically for the "attitude towards wife beating" indicators for both men and women. I replaced the "don't know" values (coded as 8) with 0 for all the sub questions ((m)v744*) and created a separate combined indicator which is equal to 1 if at least one of the sub indicators take the value of 1, and 0 if all the sub indicators are 0. This indicator is coded as missing when at least one sub indicator is missing, and the rest are 0. I was able to match the conditional averages (disaggregated by education) for both men and women for older waves using this method and (m)v005 as frequency weights with little to no differences. However, there are large differences between my conditional averages and those given on the STATcompiler website for the 2019-21 wave. The website shows a completely different trend (the share of men who justify wife beating increases by level of education) compared to what I'm getting (the share of men who justify wife beating decreases by education level) for 2019-21. I was wondering if I'm missing something.

Thank you for your help.
Re: Issues with replicating STATcompiler results for India [message #28454 is a reply to message #28451] Tue, 09 January 2024 12:00 Go to previous messageGo to next message
Bridgette-DHS is currently offline  Bridgette-DHS
Messages: 3043
Registered: February 2013
Senior Member
Following is a response from Senior DHS staff member, Tom Pullum:

Looking just at women (assuming that the code for men would be similar), I compared the results on STATcompiler with the results in Table 14.14.1 of the final report on the NFHS-5. They are not the same. I get a perfect match with the totals row of the Table 14.14.1 using the Stata lines pasted below. We will look into why STATcompiler differs from Table 14.14.1 and post a follow-up response.

* Attitudes toward wife beating
* Match the totals row of table 14.14.1 in the NFHS-5 final report

use v005 v744* s943* using "C:\Users\26216\ICF\Analysis - Shared Resources\Data\DHSdata\IAIR7EFL.DTA", clear

gen wt=v005/1000000
tab1 v744* s943* [iweight=wt]

* Don't know is classified with no 
foreach ll in a b c d e {
gen     `ll'=100*v744`ll'
replace `ll'=0 if v744`ll'==8
}

foreach ll in f g {
gen     `ll'=100*s943`ll'
replace `ll'=0 if s943`ll'==8
}

egen any=rowtotal(a b c d e f g), missing
replace any=100 if any>0 & any<.

tabstat a b c d e f g any [fweight=v005], statistics(mean)

total wt if any<.

* This matches the indicator exactly.  However, it does not match the numbers in STATcompiler 

/*
v744a           byte    %8.0g      V744A      beating justified if wife goes out without telling husband
v744b           byte    %8.0g      V744B      beating justified if wife neglects the children
v744c           byte    %8.0g      V744C      beating justified if wife argues with husband
v744d           byte    %8.0g      V744D      beating justified if wife refuses to have sex with husband
v744e           byte    %8.0g      V744E      beating justified if wife burns the food
s943f           byte    %8.0g      S943F      justifies domestic violence: wife unfaithful
s943g           byte    %8.0g      S943G      justifies domestic violence: wife disrespect

Re: Issues with replicating STATcompiler results for India [message #28465 is a reply to message #28454] Thu, 11 January 2024 07:52 Go to previous message
Bridgette-DHS is currently offline  Bridgette-DHS
Messages: 3043
Registered: February 2013
Senior Member

Following is an additional response from Senior DHS staff members, Blake Zachary and Tom Pullum:

We have confirmed that the numbers in tables 14.14.1 and 2 are consistent with the data files and can be reproduced with the Stata lines given in the previous response. The estimates on STATcompiler are incorrect. Thanks for spotting this. The estimates on STATcompiler will be updated soon.
Previous Topic: Reproducing Table 11.20 in NFHS-4 and NFHS-5 Reports
Next Topic: Household structure of NFHS-4
Goto Forum:
  


Current Time: Sun Apr 28 09:59:30 Coordinated Universal Time 2024