pysyncrosim.library.Library.scenarios

Library.scenarios(name=None, project=None, sid=None, pid=None, overwrite=False, optional=False, summary=None, results=False)

Retrieves a Scenario or DataFrame of Scenarios in this Library.

Parameters:
  • name (String, Int, or List of these, optional) – Scenario name. If an integer is given, the value will be parsed as as Scenario ID. The default is None.

  • project (Project, String, or Int, optional) – Project the Scenario belongs to. If no Project is specified when creating a new Scenario, the “Definitions” default Project is used. The default is None.

  • sid (Int or List of Ints, optional) – Scenario ID. If both name and sid are specified, the sid is used. The default is None.

  • pid (Int, optional) – Project ID. The default is None.

  • overwrite (Logical, optional) – Overwrites an existing Scenario. The default is False.

  • optional (Logical, optional) – Return optional information. The default is False.

  • summary (Logical, optional) – When name and sid is None, if True, returns a DataFrame of information on existing Scenarios. Otherwise returns a list of Scenario class instances.

  • results (Logical, optional) – Return only a list of Results Scenarios. The default is False.

Returns:

If a name or sid is specified, returns a Scenario class instance. If no name or sid is specified, and summary is set to False, returns a list of Scenario class instances. If no name or sid is specified and summary is set to True, returns a pandas.DataFrame of Scenario information for this Library.

Return type:

Scenario, List of Scenarios, or pandas.DataFrame