Modeling differential effects of health interventions across a heterogeneous population