The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Countries » Other countries » Any Anaemia Ghana DHS 2022 (I got a different value)
Any Anaemia Ghana DHS 2022 [message #30656] Tue, 14 January 2025 22:23 Go to next message
backclac is currently offline  backclac
Messages: 28
Registered: August 2023
Member
Hello
I am analyzing anaemia using KR files from the GDHS 2008, 2014, and 2022. The prevalence of "any anaemia" among 6-59 month-olds in rural areas (v025) differs from the GDHS report. Below is the STATA do.file syntax used:

* Set the survey design variables
*weighted

gen wt822=v005/1000000

*Preparing the dataset as a survey Dataset

svyset [pweight=wt822], strata(v023)psu(v021)




*****************RECODE VARIABLES**********************************

* dataset for only rural Ghana
tab v025
keep if v025==2
tab v025

*Outcome
*tab hw57



**outcome variables**


tab hw57
* adding all forms of anaemia together as one ALLanemia22
recode hw57(1 2 3=1 "anemia") (4 9=0 "not_anemic"), gen (ALLanemia822)

tab ALLanemia822


My results: 1258, 1061 and 1334 anaemic children(6-59 months) for the years 2008, 2014 and 2022, respectively


Where did I go wrong? Please advise me.

[Updated on: Tue, 14 January 2025 22:24]

Report message to a moderator

Re: Any Anaemia Ghana DHS 2022 [message #30661 is a reply to message #30656] Wed, 15 January 2025 11:27 Go to previous messageGo to next message
Janet-DHS is currently offline  Janet-DHS
Messages: 932
Registered: April 2022
Senior Member
Following is a response from DHS staff member, Tom Pullum:

I believe the problem is that your results are not actually weighted. If you use svyset, then you should have "svy: tab....".

Another easy way to get weighted tables is "tab A B [iweight=v005/1000000]".

A minor point: with pweights, as in the svyset command, you do not need to divide v005 by 1000000. Whenever you use pweight, the weights are automatically normalized to have a mean of 1. You can confirm this by comparing the results from two runs, one in which you divide by 1000000 and one in which you do not. For iweight, you DO need to divide by 1000000.
Re: Any Anaemia Ghana DHS 2022 [message #30663 is a reply to message #30661] Wed, 15 January 2025 20:49 Go to previous messageGo to next message
backclac is currently offline  backclac
Messages: 28
Registered: August 2023
Member
Thank you
Please assist me with the syntax. I obtained my previous values by not dividing v005 by 1,000,000.
*DHS setup
*USING KR file for the 2008

*weighted

gen wt=v005

svyset [pweight=wt], strata(v023)psu(v021)

* dataset for only rural Ghana
tab v025
keep if v025==2
tab v025

*Outcome
tab hw57

**outcome variables**
**ALLanemia2**

tab hw57
* adding all forms of anemia together as one ALLanemia


recode hw57(1 2 3=1 "anemia") (4 9=0 "not_anemic"), gen (ALLanemia2)

tab ALLanemia2

*RESULT

RECODE of
hw57
(anemia
level) Freq. Percent Cum.

not_anemic 526 29.48 29.48
anemia 1,258 70.52 100.00

Total 1,784 100.00


According to the GDHS 2008 report, 1426 (84.1%)children were anemic in rural Ghana.


Kindly assist me with these syntaxes, for clarity. Thank you
Re: Any Anaemia Ghana DHS 2022 [message #30701 is a reply to message #30663] Tue, 21 January 2025 15:59 Go to previous messageGo to next message
Janet-DHS is currently offline  Janet-DHS
Messages: 932
Registered: April 2022
Senior Member
Following is a response from DHS staff member, Tom Pullum:

Biomarkers such as anemia, which is based on blood tests conducted on children during the household survey, can be found in both the PR and KR files. It is not always which file was used to construct a table.

You are apparently trying to match table 11.7 in the final report on the Ghana 2008 survey. It appears that this table was constructed with the KR file, because it contains the total of 2313 children age 6-59 months, but I see that there is indeed a problem with this table. Using the KR file (GHKR5AFL.dta), the following command should give the bottom row of the table, except for "any", which is obtained by adding up "severe", "moderate", and "mild":
tab hw57 if hw1>=6 [iweight=v005/1000000]
In the KR file there is no need to specify an upper age of 59 months or de facto residence. Here is what that command gives:
. tab hw57 if hw1>=6 [iweight=v005/1000000]

     anemia |
      level |      Freq.     Percent        Cum.
------------+-----------------------------------
     severe | 164.444313        7.11        7.11
   moderate | 1,016.7676       43.95       51.06
       mild | 478.457266       20.68       71.74
not anemic | 456.775979       19.74       91.49
          9 | 196.975826        8.51      100.00
------------+-----------------------------------
      Total |  2,313.421      100.00

Comparing with the bottom row of Table 11.9, this matches the total frequency, 2313. However, the percentages in the "mild", "moderate", and "severe" categories are a little too low and there are 197 (weighted) cases with the illegal code "9".

The other panels of the table should be obtained by inserting covariates after "tab". For example, the urban/rural panel should be obtained with
tab v025 hw57 if hw1>=6 [iweight=v005/1000000], row

Unfortunately, all the panels are a little off, in terms of both frequencies and percentages.

I believe that something was done behind the scenes, or outside of the KR file, to re-assign those 197 cases (the unweighted number is 193) in terms of values on the covariates as well as anemia category. I could pursue that hypothesis, but I just don't think it's worth the time.

Next, I believe that your more immediate interest is in the 2022 survey, and I think you want to match Table 11.12 in the final report on that survey.

I tried to match it with the KR file, but it turns out that the 2022 version of the anemia table comes from the PR file (GHPR8CFL.dta). You can match the bottom row of this table, except for the "any" column, with this command:
tab hc57 if hc1>=6 & hc1<=59 & hv103==1 [iweight=hv005/1000000]
The command for the urban/rural panel, for example, would be this:
tab hv025 hc57 if hc1>=6 & hc1<=59 & hv103==1 [iweight=hv005/1000000], row
Let us know if you have other questions.
Re: Any Anaemia Ghana DHS 2022 [message #30709 is a reply to message #30701] Tue, 21 January 2025 20:44 Go to previous message
backclac is currently offline  backclac
Messages: 28
Registered: August 2023
Member
The feedback is helpful and I appreciate it.
Kindly help me address the following;
1. This study will consider the anaemia tables(data) from 2008, 2014, and 2022. We would be glad if you could help us resolve all challenges or advise us on what to do.
2. Is it appropriate to do a trend or comparison analysis using the KR file in one and the PR file in a different year

Please advise me. Thank you
Previous Topic: PDHS 2017-18 Table 4.3: Age at first Marriage Table
Next Topic: Wealth Quintiles for Malawi DHS 2000
Goto Forum:
  


Current Time: Thu Jan 23 18:26:15 Coordinated Universal Time 2025