Commit 8b735a2 1 parent 15df23f commit 8b735a2 Copy full SHA for 8b735a2
File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -599,10 +599,10 @@ def update_params_for_interventions(self):
599
599
def contraception_initiation_with_interv (p_start_per_month_without_interv ):
600
600
"""Increase the probabilities of a woman starting modern contraceptives due to Pop intervention being
601
601
applied."""
602
- # TODO: remove the keys before intervention year
603
602
p_start_per_month_with_interv = {}
604
603
for year , age_method_df in p_start_per_month_without_interv .items ():
605
- p_start_per_month_with_interv [year ] = age_method_df * self .parameters ['Interventions_Pop' ].loc [0 ]
604
+ if year >= self .sim .date .year :
605
+ p_start_per_month_with_interv [year ] = age_method_df * self .parameters ['Interventions_Pop' ].loc [0 ]
606
606
return p_start_per_month_with_interv
607
607
608
608
def contraception_initiation_after_birth_with_interv (p_start_after_birth_without_interv ):
You can’t perform that action at this time.
0 commit comments