The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Topics » HIV » HIV Testing: MWAR7ADT data
HIV Testing: MWAR7ADT data [message #14374] Thu, 29 March 2018 20:28 Go to next message
martynas is currently offline  martynas
Messages: 1
Registered: March 2018
Location: Lazdijai
Hello everyone.

Recently I started looking into MWAR7ADT data for HIV testing. However, I cannot find the full definitions of variables: hivclust, hivnumb, hivline, hiv01, hiv02, hiv03, hiv05, hiv06, hiv07 and hiv08. I was not able to find such variable names in Standard Recode Manual For DHS 6 . Could anyone provide me a source (or explain) about definitions and possible values of these variables? The help would be very much appreciated.

[Updated on: Thu, 29 March 2018 20:31]

Report message to a moderator

Re: HIV Testing: MWAR7ADT data [message #14397 is a reply to message #14374] Mon, 02 April 2018 22:20 Go to previous messageGo to next message
bsheng99 is currently offline  bsheng99
Messages: 1
Registered: April 2018
I tried to match the extracted data with the 2015-2016 Malawi DHS (Table 14.3), but failed.

I did match the total number of men (7041) and corresponding prevalence. However, the age breakdowns did not match. Which age variable(s) should I use to match the DHS report?

Also, why does the total number of women in the data (8084) not match the number in Table 14.3 (7736)?
Re: HIV Testing: MWAR7ADT data [message #14750 is a reply to message #14397] Thu, 03 May 2018 14:17 Go to previous message
Messages: 1516
Registered: February 2013
Senior Member
Dear User,
A response from senior data processing expert:

For women we start with the individual recode file and select only women with a complete interview (V015 = 1)
We then try to find the woman in the HIV data file and exclude women without a valid HIV results (samptake = 0) and for those where the result was indeterminant (HIV03 = 8) (see below).
We use the HIV weights and the age for women is based on V013.

  if V015 <> 1 then skip case endif;

  { load HIV testing data  for woman }
  testdatid = concat( edit("ZZZZZZZ9",V001), edit("ZZZ9",V002), edit("ZZ9",V003) );
  samptake = loadcase( HIVTESTDAT, testdatid );

  { exclude if no test data found or if test was indeterminant }
  If not samptake or not HIV03 in 0:7,9 then
    skip case;

  rweight = HIV05 / 1000000;

  { woman's age }
  hivage   = V013;

  xtab( t1403, rweight );

For men we loop through RECHMA and we first establish whether a valid test result is available.
We check whether the man is a de-facto resident and then try to find the man in the male recode file (matched by HB0)
We then select only the men with a valid test result and use the HIV weights (see below)
  { tabulate all tables for men }
  isex = 2;
  for i in RECHMA_EDT do

    { if blood taken check if test was successful }
    samptake = 0;
    if HB63 = 1 then
      { load test data for men and modify hivres1 accordingly }
      xline = edit("ZZ9",HB0);

      testdatid = concat( edit("ZZZZZZZ9",HV001), edit("ZZZ9",HV002), edit("ZZ9",HB0) );   { Guillermo }

      samptake = loadcase( HIVTESTDAT, testdatid );
      if samptake then
        if not HIV03 in 0:7,9 then
          hivres1  = 4;   { test was performed but protocol didn't reach the end  }
          samptake = 0;   { not enough blood will not be included in the denominator }
        hivres1 = 4;     { blood taken but sample not on data file }

    if HV103(HB0) = 1 then                   { de-facto population }
      { load male questionnaire }
      maleid = concat( HHID, edit("ZZ9",HB0) );
      if loadcase( MRECODE7, maleid ) & MV015 = 1 then

        { age in five years }
         hivage   = MV013;

        { exclude if no test data found or if test was indeterminate }
        if samptake then
         rweight = HIV05 / 1000000;           { in HIV file }

          xtab( t1403, rweight );



I hope that this will help in generating the right numbers.



Previous Topic: number not matched in "Pregnant women counseled and tested for HIV"
Next Topic: Rwanda 2014 Children's HIV - population representative?
Goto Forum:

Current Time: Fri Jul 12 19:27:57 Coordinated Universal Time 2024