The DHS Program User Forum
Discussions regarding The DHS Program data and results
Home » Countries » India » Estimation of percentage of 20-24 year old women who married before the age of 18
Re: Estimation of percentage of 20-24 year old women who married before the age of 18 [message #26290 is a reply to message #26282] Fri, 03 March 2023 14:20 Go to previous messageGo to previous message
Varsha is currently offline  Varsha
Messages: 39
Registered: November 2020
Member
Hello,

gen v511x = .
codebook s309, tab(9999)
replace v511x = s309 if s309>=0 & s309<=96
codebook s308c, tab(9999)
replace v511x = int((s308c-v011)/12) if s308c>=500 & s308c<=1500
replace v511x = 99 if v501==0

local lcutoffs 15 18 20 21 25
foreach lc of local lcutoffs {
gen marr_by_`lc'=0
replace marr_by_`lc'=1 if v511x<`lc'
}

In the above codes, even if we do not assign the never-married women a value of 99 in place of ., they will anyway get a value of 0 when we run the loop. So how is the denominator going wrong? I couldn't get it.

Can you please explain it again?


 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Percentages to numbers
Next Topic: NFHS-5, Household structure
Goto Forum:
  


Current Time: Fri Oct 18 12:49:49 Coordinated Universal Time 2024