flextool icon indicating copy to clipboard operation
flextool copied to clipboard

Missing feature: Commodity price time series

Open nelliputkonen opened this issue 2 years ago • 6 comments

Commodity would need to allow price as time series. Currently only constant/period, but would be very useful e.g. in electricity trade

nelliputkonen avatar Jun 07 '23 10:06 nelliputkonen

Yes, this would be very nice. We cannot do this nicely before Toolbox adds more support to mapped parameters. At the moment, there is no reasonable way to distinguish whether the price is given for periods or for timesteps. We could do a hack around it.

The workaround at the moment is to use efficiency time series.

jkiviluo avatar Jun 11 '23 17:06 jkiviluo

There is now an easier workaround. Just use a unit with one output, no inputs, and time-varying other_operational_cost costs. conversion_method for the unit needs to be set to none.

jkiviluo avatar Oct 03 '23 07:10 jkiviluo

Great! This workaround is easy, but for findability should be added to "how to" section as well. Maybe "how to set a electricity import/export connection" would work?

nelliputkonen avatar Oct 03 '23 08:10 nelliputkonen

We're also very interested in this feature! We'll try this workaround for now!

e-zaline avatar Oct 20 '23 12:10 e-zaline

Just reminding about solving this issue. I would estimate that using electricity trade commodity time series is among the 10 first typical things a new user wants to do with FlexTool. That's why it's very peculiar for the user that this basic feature is not included while so many advanced features are.

nelliputkonen avatar Feb 20 '24 11:02 nelliputkonen

In my opinion the easiest way to do this would be to just have two separate parameters (price/price_constant and price_time). If used at the same time, the time series would just override (or give an error). It is not a "nice way" to do this, but it shouldn't be too confusing to the user as there are now just two parameters for commodities: price and C02_content. (and quite easy to implement)

ArttuTupala avatar Feb 20 '24 15:02 ArttuTupala

Arttu solved this by creating a hack in flextoolrunner.py. It goes through input file pdt_commodity and separates its content to pd_commodity and pt_commodity depending on the name of the index (whether it belongs to time or period indexes).

Still waiting for Toolbox to implement better support for mapped parameters to make a clean solution to this.

jkiviluo avatar Mar 09 '25 10:03 jkiviluo