Skip to content

Commit

Permalink
fix keyerror when generate RTS_GMLC.m
Browse files Browse the repository at this point in the history
  • Loading branch information
shipnight authored and claytonpbarrows committed Jun 10, 2024
1 parent 8688552 commit bbadcf8
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions RTS_Data/FormattedData/MATPOWER/script.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,12 +209,12 @@ def l(string, string_list):
for i, g in _generators.iterrows():
gen['model'] = 1
gen['startup'] = (
(g['Start Heat Cold MMBTU'] * g['Fuel Price $/MMBTU']) + g['Non Fuel Start Cost $']
if not np.isnan((g['Start Heat Cold MMBTU'] * g['Fuel Price $/MMBTU']) + g['Non Fuel Start Cost $']) else 0.0
(g['Start Heat Cold MBTU'] * g['Fuel Price $/MMBTU']) + g['Non Fuel Start Cost $']
if not np.isnan((g['Start Heat Cold MBTU'] * g['Fuel Price $/MMBTU']) + g['Non Fuel Start Cost $']) else 0.0
)
gen['shutdown'] = (
g['Start Heat Cold MMBTU'] * g['Fuel Price $/MMBTU']
if not np.isnan(g['Start Heat Cold MMBTU'] * g['Fuel Price $/MMBTU']) else 0.0
g['Start Heat Cold MBTU'] * g['Fuel Price $/MMBTU']
if not np.isnan(g['Start Heat Cold MBTU'] * g['Fuel Price $/MMBTU']) else 0.0
)
gen['cost'] = list()
gen['cost'] = g['io_cost']
Expand Down

0 comments on commit bbadcf8

Please sign in to comment.