The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Data » GitHub Code Share Library » Requesting for stata syntax to calculate PNC within 48 hours in Pakistan
Requesting for stata syntax to calculate PNC within 48 hours in Pakistan [message #27677] Mon, 18 September 2023 16:06 Go to next message
Margubur is currently offline  Margubur
Messages: 1
Registered: April 2023
Dear contributors,
I am trying to estimate PNC within 48 hours using KR file of PDHS. I was not able to match the percentage of PNC within 48 hours with the PDHS 2017-18 report. If possible please provide me do file.
Re: Requesting for stata syntax to calculate PNC within 48 hours in Pakistan [message #27686 is a reply to message #27677] Tue, 19 September 2023 09:05 Go to previous message
Shireen-DHS is currently offline  Shireen-DHS
Messages: 140
Registered: August 2020
Location: USA
Senior Member

Thank you for your question.

The DHS Program PNC code can be found here: er/Chap09_RH

The code is written to be run using an IR file and not the KR file. This is why you will see for instance m51_1 to indicate the most recent birth. In the KR file this would be m51.

To get the PNC estimates, please follow the instructions below:

1. Open the IR file
2. Run the entire file. This includes running the code to generate the child's age at the top using: gen age = b19_01. Running the whole file will create all the PNC indicators.
3. The variable you are asking about is rh_pnc_wm_2days
4. To check this variable generate the sampling weight: gen wt=v005/1000000
5. Tabulate the variable to check with final report: tab rh_pnc_wm_2days [iw=wt]

When I do this I get 61.9% with a denominator of 3,935 women. Table 9.10 has the same denominator but 61.6%, these minor discrepancies can sometimes occur due to how missing are defined using the data processing software and Stata and it's not large enough to be of concern.

If you prefer to use the KR file, you would need to remove all the _1 in the code.

Hope this helps.

Shireen Assaf
The DHS Program

[Updated on: Tue, 19 September 2023 09:58]

Report message to a moderator

Next Topic: Please post your questions from the GitHub code library
Goto Forum:

Current Time: Thu Jun 20 17:16:38 Coordinated Universal Time 2024