Dear Forum Members,
I am working with the DHS 2017-18 Pakistan dataset, which includes variables (b5_01 to b5_20) indicating whether children are alive within a household. These variables are arranged in descending order of birth, with bord_01 representing the oldest child and bord_20 the youngest child, where applicable.
My goal is to:
I am working with the DHS 2017-18 Pakistan dataset, which includes variables (b5_01 to b5_20) indicating whether children are alive within a household. These variables are arranged in descending order of birth, with bord_01 representing the oldest child and bord_20 the youngest child, where applicable.
My goal is to:
- Filter for Alive Children: Keep only the observations where at least one child is alive, based on non-missing values in b5_01 to b5_20.
- Rank Children by Birth Order: For each household, rank the children based on their birth order from bord_01 to bord_20, starting with the oldest child.
Comment