-
Notifications
You must be signed in to change notification settings - Fork 520
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
Improve freq argument in matrix's freq argument #106
Comments
Actually I think by simply putting the try-except clause inside the for loop might just work. for value in ts_array:
try:
ts_list.append(df.index.get_loc(value))
except KeyError:
logging.warning('Could not divide time index into desired frequency.') Something like that without breaking the for-loop. |
If you go ahead and submit a PR I'm happy to take a look at that. :) |
What is the status of this issue? I just installed the package and obviously this bug is still NOT fixed? |
This bug probably still exists. I didn't look at |
If someone has this problem and cannot cut off their timeseries (gaps between days), another solution could be to reindex time series with a complete range of dates (hh:mm:ss as necessary) and fill the value gaps with NaN. |
Try removing the
Try removing the |
Hi, My index on the dataframe has the value in "yyyy-mm-dd hh:mi:ss" format and each row is at 15 min interval. Can you tell me how to use the frequency parameter on the matrix plot? |
This is probably a very simple bug to fix. If nobody tackles it I will probably do it some time when I'm free and give a pull request. The error is that the
freq
argument frommsno.matrix()
, when activated inmissingno.py
(the code is shown below), it initiates a date_range starting from the beginning of the day. When it does not get a index value fromdf.index.get_loc(value)
, theKeyError
is catched and the operation is halted.The issue is many times this timeseries data might not begin or end on a full day cycle, aka 00:00 am. So maybe simply cut off with the range of input df will solve the problem.
PS: Hopefully the format of the issue is clear. This is my first time to raise issue so any suggestion on modifying this issue would be welcomed.
And great work with this project!
The text was updated successfully, but these errors were encountered: