Skip to content

Data source schema

All options available to load model definition data from file.

  • rows: Names of dimensions defined row-wise. Each name should correspond to a column in your data that contains index items. These columns must be to the left of the columns containing your data. Refer to #/$defs/DataSourceVals.

  • columns: Names of dimensions defined column-wise. Each name should correspond to a row in your data that contains index items. These rows must be above the rows containing your data. Refer to #/$defs/DataSourceVals.

  • source (string): Relative or absolute filepath. If relative, will be relative to the model config file used to initialise the model.

  • select (object): Select one or more index item from a dimension. Selection takes place before drop and add_dimensions, so you can select a single value from a data dimension and then drop the dimension so it doesn't find its way through to the final dataset.

    • ^[^_^\d][\w]*$
  • drop (['string', 'array']): Dimensions in the rows and/or columns that contain metadata and should therefore not be passed on to the loaded model dataset. These could include comments on the source of the data, the data license, or the parameter units. You can also drop a dimension and then reintroduce it in add_dimensions, but with different index items. Refer to #/$defs/DataSourceVals.

  • add_dimensions (object): Data dimensions to add after loading in the array. These allow you to use the same file to assign values to different parameters/dimension index items (e.g., setting flow_cap_min and flow_cap_max to the same value), or to add a dimension which would otherwise be a column containing the same information in each row (e.g., assigning the cost class to monetary for a file containing cost data). Cannot contain additional properties.

    • ^[^_^\d][\w]*$ (['string', 'array']): Keys are dimension names (must not be in rows or columns), values are index items of that dimension to add. Refer to #/$defs/DataSourceVals.

Definitions

  • DataSourceVals

    • One of

      • null

      • string

      • array

        • Items (string)