result_network.ResultStructures

result_network.ResultStructures(self, res1d)

Class for wrapping ResultData structure data items.

By itself it is also a dict, which contains mapping between structure ID and a ResultStructure object.

Parameters

Name Type Description Default
res1d Res1D Res1D object the structure data items belong to. required

Attributes

Name Description
derived_quantities A list of available derived quantities.
group The TimeSeriesIdGroup associated with these locations.
locations A list of location objects (e.g. ).
names A list of location names (e.g. MUIDs).
quantities A list of available quantities.
res1d The Res1D instance that these locations belong to.

Methods

Name Description
read Read the time series data for all quantities at these locations into a DataFrame.
to_dataframe Read the time series data for all quantities at these locations into a DataFrame.

read

result_network.ResultStructures.read(column_mode=None, include_derived=False)

Read the time series data for all quantities at these locations into a DataFrame.

Parameters

Name Type Description Default
column_mode str(optional) Specifies the type of column index of returned DataFrame. ‘all’ - column MultiIndex with levels matching TimeSeriesId objects. ‘compact’ - same as ‘all’, but removes levels with default values. ‘timeseries’ - column index of TimeSeriesId objects None
include_derived bool Include derived quantities. False

Returns

Name Type Description
pd.DataFrame Time series data of every quantity at these locations.

to_dataframe

result_network.ResultStructures.to_dataframe(
    column_mode=None,
    include_derived=False,
)

Read the time series data for all quantities at these locations into a DataFrame.

Alias for read() method.

Parameters

Name Type Description Default
column_mode str(optional) Specifies the type of column index of returned DataFrame. ‘all’ - column MultiIndex with levels matching TimeSeriesId objects. ‘compact’ - same as ‘all’, but removes levels with default values. ‘timeseries’ - column index of TimeSeriesId objects None
include_derived bool Include derived quantities. False

Returns

Name Type Description
pd.DataFrame Time series data of every quantity at these locations.