Skip to content

Instantly share code, notes, and snippets.

@dpick
Created August 10, 2011 17:50
Show Gist options
  • Save dpick/1137614 to your computer and use it in GitHub Desktop.
Save dpick/1137614 to your computer and use it in GitHub Desktop.
inpatient = @questions["stay_overnight_at_the_hospital_one_or_more_times"]
outpatient = @questions["have_one_or_more_outpatient_hospital_vists"]
emergency = @questions["seek_care_at_the_emergency_room"]
case
when inpatient == 0 && outpatient == 0 && emergency == 0
@draws
when inpatient == 0 && outpatient == 0 && emergency >= 1
top_draws(80)
when inpatient == 0 && outpatient >= 1 && emergency == 0
top_draws(80)
when inpatient >= 1 && outpatient == 0 && emergency == 0
top_draws(50)
when inpatient == 0 && outpatient >= 1 && emergency >= 1
top_draws(50)
when inpatient >= 1 && outpatient >= 1 && emergency == 0
top_draws(40)
when inpatient >= 1 && outpatient == 0 && emergency >= 1
top_draws(40)
when inpatient >= 1 && outpatient >= 1 && emergency >= 1
top_draws(25)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment