Open griffinsharps opened 1 week ago
Thank you!
Griffin Sharps (502)-472-5602
On Wed, Jun 26, 2024 at 7:42 AM Pavel Makarchuk @.***> wrote:
@.**** requested changes on this pull request.
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654695630 :
@@ -0,0 +1,12 @@ +description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles. +metadata:
- unit: miles
- period: year
- label: High Manufacturer's Suggested Price
- reference:
- title: NYSERDA Drive Clean Implementation Manual
- href: https://www.nyserda.ny.gov/All-Programs/Drive-Clean-Rebate-For-Electric-Cars-Program/Dealers/Dealer-Resources
Could we link to the implementation manual https://www.nyserda.ny.gov/-/media/Project/Nyserda/Files/Programs/Drive-Clean-NY/implementation-manual.pdf and add the relevant page to the hyper link (page where we can find the value of the parameter file) e.g. ...manual.pdf#page=8 in this case
On policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_range_rebate.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654698580 :
lets rename this to amount.yaml
In changelog_entry.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654702485 :
@@ -0,0 +1,4 @@ +- bump: minor
- changes:
- added:
- NYSERDA Drive Clean Point of Sale Rebate
⬇️ Suggested change
- NYSERDA Drive Clean Point of Sale Rebate
- NYSERDA Drive Clean Point of Sale Rebate.
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654703889 :
@@ -0,0 +1,12 @@ +description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles.
⬇️ Suggested change
-description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles. +description: New York provides a flat Drive Clean point-of-sale rebate for vehicles with a base MSRP over this amount.
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654705117 :
@@ -0,0 +1,12 @@ +description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles. +metadata:
- unit: miles
- period: year
- label: High Manufacturer's Suggested Price
⬇️ Suggested change
- label: High Manufacturer's Suggested Price
- label: New York Drive Clean point-of-sale flat rebate MSRP threshold
On policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654707252 :
lets organize the MSRP related files as follows: drive_clean/flat_rebate/ - folder structure msrp_threshold.yaml - $42,000 amount.yaml - $500
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp_rebate.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654737577 :
@@ -0,0 +1,11 @@ +description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles. +metadata:
- unit: currency-usd
- period: year
- label: High Manufacturer's Suggested Price
⬇️ Suggested change
- label: High Manufacturer's Suggested Price
- label: New York Drive Clean point-of-sale flat rebate amount
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_high_msrp_rebate.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654738851 :
@@ -0,0 +1,11 @@ +description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles.
⬇️ Suggested change
-description: New York minimizes the Drive Clean point-of-sale rebate for high-price vehicles. +description: New York provides the following flat Drive Clean point-of-sale rebate vehicles with a base MSRP over a certain threshold.
In policyengine_us/parameters/gov/states/ny/nyserda/drive_clean/drive_clean_range_rebate.yaml https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654740273 :
@@ -0,0 +1,34 @@ +description: The Drive Clean program offers a different rebate based on the all-electric range of the vehicle and the date of its purchase.
⬇️ Suggested change
-description: The Drive Clean program offers a different rebate based on the all-electric range of the vehicle and the date of its purchase. +description: New York provides the following Drive Clean point-of-sale rebate amount, based on the all-electric range of the vehicle.
In policyengine_us/variables/gov/states/ny/nyserda/drive_clean/drive_clean_rebate.py https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654744783 :
- if vehicle_cost >= p.drive_clean_high_msrp:
- cost_rebate = p.drive_clean_high_msrp_rebate
- return cost_rebate
- else:
- vehicle_all_electric_range = tax_unit("drive_clean_vehicle_electric_range", period)
- range_rebate = p.rebate.calc(vehicle_all_electric_range)
⬇️ Suggested change
- if vehicle_cost >= p.drive_clean_high_msrp:
- cost_rebate = p.drive_clean_high_msrp_rebate
- return cost_rebate
- else:
- vehicle_all_electric_range = tax_unit("drive_clean_vehicle_electric_range", period)
- range_rebate = p.rebate.calc(vehicle_all_electric_range)
First compute the amount based on electric range
- vehicle_range = tax_unit("drive_clean_vehicle_electric_range", period)
- rebate_amount_based_on_range = p.rebate.calc(vehicle_all_electric_range)
If the vehicle cost exceeds a certain threshold, a flat amount is applied
- vehicle_over_msrp_threshold = vehicle_cost >= p.drive_clean_high_msrp
- flat_amount = p.drive_clean_high_msrp_rebate
- return where(vehicle_over_msrp_threshold, flat_amount, rebate_amount_based_on_range)
In policyengine_us/variables/gov/states/ny/nyserda/drive_clean/drive_clean_vehicle_cost.py https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654746940 :
@@ -0,0 +1,10 @@ +from policyengine_us.model_api import * + +class drive_clean_vehicle_cost(Variable):
- value_type = float
- entity = TaxUnit # TODO: Check if this is right. Not a tax credit.
- label = "Vehicle Price"
- unit = USD
- definition_period = YEAR
- reference = "https://www.nyserda.ny.gov/All-Programs/Drive-Clean-Rebate-For-Electric-Cars-Program"
If this is a definition that is given specifically by nyserda lets move to the nyserda folder and add nyserda_ to the class and file names
In policyengine_us/variables/gov/states/ny/nyserda/drive_clean/drive_clean_vehicle_electrical_range.py https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654747478 :
@@ -0,0 +1,10 @@ +from policyengine_us.model_api import * + +class drive_clean_vehicle_electric_range(Variable):
- value_type = float
- entity = TaxUnit # TODO: Check if this is right. Not a tax credit.
- label = "All-Electric Vehicle Range"
- unit = miles
- definition_period = YEAR
- reference = "https://www.nyserda.ny.gov/All-Programs/Drive-Clean-Rebate-For-Electric-Cars-Program"
same suggestion as for the drive_clean_vehicle_cost
In policyengine_us/variables/gov/states/ny/nyserda/drive_clean/drive_clean_rebate.py https://github.com/PolicyEngine/policyengine-us/pull/4688#discussion_r1654745580 :
- if vehicle_cost >= p.drive_clean_high_msrp:
- cost_rebate = p.drive_clean_high_msrp_rebate
- return cost_rebate
- else:
- vehicle_all_electric_range = tax_unit("drive_clean_vehicle_electric_range", period)
- range_rebate = p.rebate.calc(vehicle_all_electric_range)
adjust the parameter paths based on the suggestions above
— Reply to this email directly, view it on GitHub https://github.com/PolicyEngine/policyengine-us/pull/4688#pullrequestreview-2141612181, or unsubscribe https://github.com/notifications/unsubscribe-auth/AVLHGDFBAV7OYTYH2JXGR4TZJKZKVAVCNFSM6AAAAABJ4DHGLOVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDCNBRGYYTEMJYGE . You are receiving this because you authored the thread.Message ID: @.***>
Fixes #4642