Visualization

class pomato.visualization.Visualization(wdir, data)

The visualization module of Pomato bundles processing and plotting methods to visualize pomato results.

Its instantiated with access to DataManagement and in extention to market results instantiated into in it. The plotting functionality is implemented with the plotting library Plotly.

Methods

create_geo_plot(market_result[, ...])

Creates Geoplot of market result.

create_zonal_geoplot(market_result[, ...])

create_generation_plot(market_result[, ...])

Create interactive generation plot.

create_generation_pie(market_result[, ...])

Create pie chart, showing generation by type/fuel in relation to the total generation.

create_generation_overview(market_results[, ...])

Create generation overview of multiple model results.

create_available_intermittent_capacity_plot(data)

Visualize available intermittent generation capacities over time.

create_installed_capacity_plot(data[, ...])

Create plot visualizing installed capacity per market area.

create_storage_plot(market_result[, ...])

Create plot storage utilization.

create_lineflow_plot(market_result, lines[, ...])

Create line flow plot for selected lines.

create_fb_domain_plot(fb_domain[, ...])

Create FlowBased Domain plot.

create_cost_overview(market_results[, ...])

Create objective value overview of multiple model results.

create_merit_order([data, zones, timestep, ...])

Create merit order of the input data.

create_available_intermittent_capacity_plot(data, zones=None, show_plot=True, filepath=None)

Visualize available intermittent generation capacities over time.

Parameters:
dataDataManagement

Pomato data object.

zones: list, optional,

Subset of zones to include in the plot.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_cost_overview(market_results, show_plot=True, filepath=None)

Create objective value overview of multiple model results.

Parameters:
market_resultslist of DataManagement

Market results which is plotted.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_fb_domain_plot(fb_domain, show_plot=True, filepath=None)

Create FlowBased Domain plot.

This is a copy of the previous create_fbmc_figure() using plotly instead of matplotlib. This allows for proper integration in the Dashboard functionality including interaction with the geo plot.

Input argument remains an instance of FBDomain which can be created by utilizing FBDomainPlots() module.

create_generation_overview(market_results, zones=None, show_plot=True, filepath=None, return_data=False)

Create generation overview of multiple model results.

Parameters:
market_resultslist of Results or dict(title, Results)

Market results which is plotted.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_generation_pie(market_result, show_plot=True, filepath=None)

Create pie chart, showing generation by type/fuel in relation to the total generation.

The resulting figure generation by fuel/type/technology as a pie chart, illustrating the share of each type. The figure is generated using the plotly package and can be returned or saved depending on the input arguments.

Parameters:
market_resultDataManagement Market result which is plotted.

show_plot : bool, optional Shows plot after generation. If false, returns plotly figure instead. By default True. filepath : pathlib.Path, str, optional If filepath is supplied, saves figure as .html, by default None

create_generation_plot(market_result, nodes=None, show_plot=True, filepath=None)

Create interactive generation plot.

The generation plot shows generation by fuel/type/technology over the model horizon for the specified market result and optionally subset of nodes. The figure is generated using the plotly package and can be returned or saved depending on the input arguments.

Parameters:
market_resultResult

Market result which is plotted.

nodes: list, optional,

Show only generation at the supplied subset of nodes. By default None, which shows all generation.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_geo_plot(market_result, show_redispatch=False, show_prices=False, show_infeasibility=False, show_curtailment=False, timestep=None, highlight_nodes=None, highlight_zones=None, line_color_threshold=0, line_loading_range=(0, 100), highlight_lines=None, line_color_option=0, redispatch_input=None, redispatch_size_reference=None, redispatch_threshold=0, show_plot=True, filepath=None, vector_plot=False)

Creates Geoplot of market result.

The geoplot is a interactive plotly figure showing lineloading, redispatch and prices depending on optional arguments.

Parameters:
market_resultResults

Market result which is plotted.

show_redispatchbool, optional

Include redispatch, this requires the market_result argument to be the redispatch result and the corresponding market results to be instantiated. Defaults to False.

show_pricesbool, optional

Include a visual representation of the locational marginal prices, by default False.

timestepint, string, optional

Timestep for which the load, redispatch or price is plotted. Can be timestep index or timestep string identifier. If None, average values are presented. Defaults to None.

line_color_optionint, optional

Lines are colored based on N-0 flows (0), N-1 flows (1) and voltage levels (2), all gray (3). by default 0.

line_loading_rangetuple(int), optional

Show line colors in range of percentage lineload, defaults to (0, 100).

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_installed_capacity_plot(data, zones=None, aggregate=None, show_plot=True, filepath=None)

Create plot visualizing installed capacity per market area.

The installed capacity plot visualizes the installed capacity as stacked bar charts. The figure is generated using the plotly package and can be returned or saved depending on the input arguments.

Parameters:
dataDataManagement or Results, optional

Data to plot, defaults to class attribute data.

zoneslist, optional

Subset of zones to include in the capacity plot.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_lineflow_plot(market_result, lines, show_plot=True, filepath=None)

Create line flow plot for selected lines.

The lineflow plot contains three different plots, showing the N-0, N-1 and a lineflow duration plot for the specified lines. The figure is generated using the plotly package and can be returned or saved depending on the input arguments.

Parameters:
market_resultDataManagement

Market result which is plotted.

lineslist,

List of line elements to be included in the plot.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_merit_order(data=None, zones=None, timestep=None, show_plot=True, filepath=None)

Create merit order of the input data.

Parameters:
dataDataManagement or Results, optional

Data to plot, defaults to class attribute data.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None

create_storage_plot(market_result, storages=None, show_plot=True, filepath=None)

Create plot storage utilization.

The storage plot visualizes the usage of electricity storages over the model horizon. The values are summed over all storage units, or units can be specified by the optional input argument. The figure is generated using the plotly package and can be returned or saved depending on the input arguments.

Parameters:
market_resultDataManagement

Market result which is plotted.

storageslist, optional

Only show selected storage units.

show_plotbool, optional

Shows plot after generation. If false, returns plotly figure instead. By default True.

filepathpathlib.Path, str, optional

If filepath is supplied, saves figure as .html, by default None