pytuflow.NCGrid.data_types#
- NCGrid.data_types(filter_by=None)#
Return the available data types for the given filter.
The available filters are:
None
- no filter, return all available data typesscalar/vector
- filter by scalar or vector data typesmax/min
- filter by data types that have maximum or minimum valuesstatic/temporal
- filter by static or temporal data types
Filters can be combined by delimiting with a forward slash, e.g.
'scalar/max'
.- Parameters:
filter_by (str, optional) – The filter to apply to the data types.
- Returns:
The list of data types available.
- Return type:
list[str]
Examples
>>> nc = NCGrid('./path/to/result.nc') >>> nc.data_types() ['water level', 'depth', 'velocity', 'z0', 'max water level', 'max depth', 'max velocity', 'max z0', 'tmax water level']
Get only the temporal data types:
>>> nc.data_types('temporal') ['water level', 'depth', 'velocity', 'z0']
Get only the vector data types:
>>> nc.data_types('vector') ['velocity', 'max velocity']