coerce_increasing_time
coerce_increasing_time#
- echopype.qc.coerce_increasing_time(ds, time_name='ping_time', local_win_len=100)#
Coerce a time coordinate to always flow forward.
This is to correct for problems sometimes observed in EK60 data where a time coordinate (
ping_time
ortime1
) would suddenly go backward for one ping but with the rest of the pinging interval undisturbed.- Parameters
- dsxr.Dataset
a dataset for which the time coordinate needs to be corrected
- time_namestr
name of the time coordinate to be corrected
- local_win_lenint
half length of the local window within which the median pinging interval is used to infer the correct next ping time
- Returns
- the input dataset but with specified time coordinate coerced to flow forward