Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scale-type phase-out parameter structure #1133

Open
MaxGhenis opened this issue Jul 6, 2022 · 0 comments
Open

Scale-type phase-out parameter structure #1133

MaxGhenis opened this issue Jul 6, 2022 · 0 comments

Comments

@MaxGhenis
Copy link
Contributor

MaxGhenis commented Jul 6, 2022

Governments often structure benefit programs and tax credits with a maximum value, a phase-out start, and a phase-out rate. For example, the US Supplemental Security Income program phases out with income at 50% above an exemption; from the OpenFisca US docs:

image

We model these with sets of parameters for maximum_amount, phase_out_start, and phase_out_rate (e.g. see the US Child Tax Credit), and then code structures like:

reduction = max_(0, income - phase_out_start) * phase_out_rate
return max_(0, maximum_amount - reduction)

I'd suggest a parameter structure that captures these elements and automatically computes the value via phase_out_parameter.calc(income), in the vein of parameter scales. I think this would reduce code duplication and room for error.

@nikhilwoodruff @rickecon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant