Quick Start

Installation

  1. Install the most recent version of [Julia], preferably using the Juliaup version multiplexer (https://github.com/JuliaLang/juliaup)

  2. Install the package EnergyModelsGUI by running:

    ] add EnergyModelsGUI

Use

Note

EnergyModelsGUI extends EnergyModelsBase with a graphical user interface. As a consequence, it requires the declaration of a Case in EnergyModelsX.

To this end, you also have to add the packages EnergyModelsBase and potentially EnergyModelsGeography and EnergyModelsInvestments to create your energy model cases first.

If you already have constructed a Case in EMX you can view this case with

using EnergyModelsGUI

GUI(case)

This allows you to investigate all provided parameters, but does not show you the results from the analysis. The results from a JuMP model can be visualized through the keyword argument model for a given JuMP model m:

GUI(case; model=m)

It is furthermore possible to visualize results from a saved model run. This however requires you to first save the results from a model run through the function save_results. You can then visualize the results from a saved model run, again with the keyword argument model.

For a given JuMP model m, this approach is given by

# Specify the directory for saving the results and save the results
dir_save = `path-to-results`
save_results(m; directory = dir_save)

# Load the results from the saved directory
GUI(case; model = dir_save)
Requirements for loading from file
  1. You must always provide a Case in EnergyModelsX corresponding to the model results when reading input data. This case can be created anew from corresponding functions. It cannot be a saved Case as the pointers to specific instances of, e.g., Links are not recreated when loading a Case.
  2. You must use the function save_results for saving your results as we require the meta data when reading the CSV files for translating the data into the correct format.

A complete overview of the keyword arguments available for the GUI functions is available in its docstring.

Example

The GUI and its functionality is described through an example. You can also load different examples from the folder, if desired