interpolateDataAtRegularInterval()

Signature:

resample(
    operation: str,
    interval: Union[
            TimeSeries,
            hec.TimeSpan,
            datetime.timedelta,
            NoneType
        ] = None,
    offset: Union[
            int,
            hec.TimeSpan,
            datetime.timedelta,
            NoneType
        ] = None,
    start_time: Union[
            str,
            datetime.datetime,
            hec.HecTime,
            NoneType
        ] = None,
    end_time: Union[
            str,
            datetime.datetime,
            hec.HecTime,
            NoneType
        ] = None,
    max_missing_percent: float = 25.0,
    entire_interval: Optional[bool] = None,
    before: Union[str, float] = 0.0,
    after: Union[str, float] = 'LAST',
    in_place: bool = False
) -> TimeSeries

Detailed Documentation

The hec-python-library equivalent of Jython method interpolateDataAtRegularInterval():

If in_place=True, the instance itself is modified. In this case the returned value (which can be ignored in python) is the modified instance, which can be used in chaining methods.

Example:

from hec import Interval

intvl = Interval.get_cwms("1Day")

ts2 = ts1.resample("Interpolate", intvl)

Signature:

iresample(
    operation: str,
    interval: Union[
            TimeSeries,
            hec.TimeSpan,
            datetime.timedelta,
            NoneType
        ] = None,
    offset: Union[
            int,
            hec.TimeSpan,
            datetime.timedelta,
            NoneType
        ] = None,
    start_time: Union[
            str,
            datetime.datetime,
            hec.HecTime,
            NoneType
        ] = None,
    end_time: Union[
            str,
            datetime.datetime,
            hec.HecTime,
            NoneType
        ] = None,
    max_missing_percent: float = 25.0,
    entire_interval: Optional[bool] = None,
    before: Union[str, float] = 0.0,
    after: Union[str, float] = 'LAST',
) -> TimeSeries

Convenience method for calling interpolateDataAtRegularInterval(...) with in_place=True.

Example:

from hec import Interval

intvl = Interval.get_cwms("1Day")

ts1.iresample("Interpolate", intvl)