PyPSA / pypsa-usa

PyPSA-USA: An Open-Source Energy System Optimization Model for the United States
https://pypsa-usa.readthedocs.io
MIT License
52 stars 20 forks source link

Change `get_energy_timeseries` function to pypsa dispatch function #242

Open trevorb1 opened 6 months ago

trevorb1 commented 6 months ago

Feature Request

We should change our get_energy_timeseries(n) function to the pypsa.statistics.StatisticsAccessor.dispatch() method. The advantage of this is that we can simplify our code and take advantage of pypsa testing their functions. Note, we need to double check we care assuming same logic for link power dispatch

Suggested Solution

I believe these two are equivalent:

  1. (current) get_energy_timeseries(n)
  2. (proposed) StatisticsAccessor(n).dispatch(aggregate_time=False).T

Additional Info

No response

trevorb1 commented 6 months ago

dispatch will also bring in the demand timeseries, which will further simplify the plot_production graphs