Skip to content

Apparent inconsistency in HSI_CardioMetabolicDisorders_Refill_Medication #1748

@marghe-molaro

Description

@marghe-molaro

There appear to be an inconsistency within the HSI HSI_CardioMetabolicDisorders_Refill_Medication.

As per the HSI description,

If the person is flagged as not being on medication, then the event does nothing and returns a blank footprint.
If it does not run, then person ceases to be on medication and no further refill HSI are scheduled.

the HSI ensures that if a person is not on treatment, the appt footprint is returned as blank, no further HSIs are scheduled, and the rest of the HSI doesn't run.

if not person[f'nc_{self.condition}_on_medication']:
# This person is not on medication so will not have this HSI
# Return the blank_appt_footprint() so that this HSI does not occupy any time resources
return self.sim.modules['HealthSystem'].get_blank_appt_footprint()

If, on the other hand, a person is on treatment, the HSI goes ahead and checks whether relevant consumables are available.

If these are not available, it is assumed that the person will come back again the next day to get a refill with a probability controlled by parameter pr_seeking_further_appt_if_drug_not_available which

# If person 'decides to' seek another appointment, schedule a new HSI appointment for tomorrow.
# NB. With a probability of 1.0, this will keep occurring, and the person will never give-up coming back to
# pick-up medication.
if (m.rng.random_sample() <
m.parameters[f'{self.condition}_hsi'].get('pr_seeking_further_appt_if_drug_not_available')):
self.sim.modules['HealthSystem'].schedule_hsi_event(
hsi_event=self,
topen=self.sim.date + pd.DateOffset(days=1),
tclose=self.sim.date + pd.DateOffset(days=15),
priority=1
)

For all conditions except lower back pain, is quite high (80%)
./cmd/ResourceFile_cmd_condition_hsi/hypertension.csv:pr_seeking_further_appt_if_drug_not_available,0.8,,
./cmd/ResourceFile_cmd_condition_hsi/chronic_kidney_disease.csv:pr_seeking_further_appt_if_drug_not_available,0.8,,
./cmd/ResourceFile_cmd_condition_hsi/chronic_lower_back_pain.csv:pr_seeking_further_appt_if_drug_not_available,0.1,,
./cmd/ResourceFile_cmd_condition_hsi/diabetes.csv:pr_seeking_further_appt_if_drug_not_available,0.8,,
./cmd/ResourceFile_cmd_condition_hsi/chronic_ischemic_hd.csv:pr_seeking_further_appt_if_drug_not_available,0.8,,

However, because the treatment status in this case is set to False, when the person comes back the following day they immediately fall off treatment (as described above), and will have no opportunity to seek further appts, despite initially assuming that this should happen with 80% probability.

# If medication was not available, the person ceases to be taking medication
df.at[person_id, f'nc_{self.condition}_on_medication'] = False

Unless we are missing something, this suggests an inconsistency in the HSI logic.

Because the HSI's did_not_run also sets the treatment status to False, this also means that any delays in the HSI also cause the person to immediately fall off treatment, as described in Issue #1632

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions