fn price_markets(
model: &Model,
solution: &Solution<'_>,
year: u32,
markets: &[(CommodityID, RegionID)],
shadow_prices: &CommodityPrices,
annual_activities: &mut Option<HashMap<AssetRef, Activity>>,
result: &mut CommodityPrices,
)Expand description
Calculate prices for a collection of independent markets and insert them into result.
result serves as both the source of input prices (prices of input commodities from
upstream markets already computed) and the destination for newly computed prices.
ยงArguments
model- The modelsolution- Solution to dispatch optimisationyear- The year for which prices are being calculatedmarkets- The markets to calculate prices forshadow_prices- Shadow prices for all commoditiesannual_activities- Optional map of annual activities for all assets, used for full cost pricing. If not provided, it will be calculated on demand if at least one market uses full cost pricing.result- In-progress map of calculated prices, which will be extended with the newly calculated prices for these markets