gyanz / pydsstools

Python library for simple HEC-DSS functions
MIT License
83 stars 36 forks source link

Time Series types #6

Closed danhamill closed 5 years ago

danhamill commented 5 years ago

I have a question about how TimeSeriesContainer containers interpret time series types. In the examples you have:

dss_file = "example.dss"
pathname = "/REGULAR/TIMESERIES/FLOW//1HOUR/Ex1/"
tsc = TimeSeriesContainer()
tsc.pathname = pathname
tsc.startDateTime = "15JUL2019 19:00:00"
tsc.numberValues = 5
tsc.units = "cfs"
tsc.type = "INST"
tsc.interval = 1
tsc.values = [100,UNDEFINED,500,5000,10000]

When I run this code, I get dss time series of the type `INST-VAL'. Specific questions:

  1. Why wasn't this iterpreted as INST-CUM?

Is there a docstring that explains this logic?

Thanks,

Dan

gyanz commented 5 years ago

INST is not a valid type for time series - this is a type in the example. The HEC-DSS C library probably defaults to INST-VAL if type info is invalid.