Xns11
Xns11 API
- class mikeio1d.xns11.QueryData(topoid_name, reach_name=None, chainage=None)[source]
A query object that declares what data should be extracted from a .xns11 file.
- Parameters:
topoid_name (
str
) – Topo ID, must be passedreach_name (
str
, optional) – Reach name, consider all the reaches if Nonechainage (
float
, optional) – chainage, considers all the chainages if None
Examples
>>> QueryData('topoid1', 'reach1', 10) # is a valid query. >>> QueryData('topoid1', 'reach1') # requests all the points for `topoid1` of `reach1`. >>> QueryData('topoid1') requests all the points for `topid1` of the file.
- mikeio1d.xns11.read(file_path, queries)[source]
Read the requested data from the xns11 file and return a Pandas DataFrame.
- Parameters:
file_path (
str
) – full path and file name to the xns11 file.queries (
a single query
ora list
ofqueries
) – QueryData objects that define the requested data.
- Returns:
pd.DataFrame