-
Notifications
You must be signed in to change notification settings - Fork 145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Question: unequally spaced timeseries #60
Comments
@ajdapretnar Seasonal decomposition in ADTK requires the input follows equally spaced time series, as you noticed. Therefore, the time series should be resampled with a constant frequency, for example 15 min. If you got a ValueError regarding NaN values, the reason is that your resampling may introduce NaN value to the new time series (in your example, 9:45 will have NaN value). Currently, SeasonAD does not support time series with NaN, unless the NaN values are on the starting or ending part of the time series and they will be ignored. In the
If you want to fill NaN with forward or backward filling instead of interpolation, I believe you can also use the |
Thanks, this is useful! Will try it. |
My df is not having any null values but i am still getting this error when going to higher samples. |
try s_train.resample('15min').ffill() if adtk.data doesn't have resample |
Removed adtk.data.resample because its functionality is highly overlapped with pandas resampler module |
First, big thanks for a nice library! Very useful!
I am trying to follow your Quick Start for SeasonalAD, but I am encountering a problem. My timeseries seem be to unequally spaced (e.g. 09:05, 09:15, 9:30, 9:55). Hence the SeasonalAD complains:
RuntimeError: Series does not follow any known frequency (e.g. second, minute, hour, day, week, month, year, etc.
How to overcome this?
I have tried rounding my series to 15min, removing duplicates and resampling.
Obviously nothing worked. Any ideas how to solve this? I wish to retain as much granularity as possible.
The text was updated successfully, but these errors were encountered: