cap program drop Hbp_R_intervene0
program define Hbp_R_intervene0
	syntax [varlist] [if] [in], is_startyr(integer)

* Hbp R Initial Intervention
*	for approx half of the population, if the person is overweight or obese and doesnt have hbp, then set them to be treated
if `is_startyr' {
		cap drop hibpdraw
		gen hibpdraw = uniform()
		replace treat_now = (obese == 1 | overwt) & hibpe == 0  & hibpdraw <=0.5 if `touse'
		replace treat_effective = 0  if `touse'
  }
	else {
		replace diabdraw = uniform() if diabdraw == .
	  }
	}
end