-
Notifications
You must be signed in to change notification settings - Fork 216
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
Pandas Support #36
Comments
No pitfalls that I can think of. Feel free to add this. |
I think we need this, especially if I want to leverage pandas timeseries (Series) objects. Right now facing issues trying to get my time series objects into the APIs from this library. Any good documentation available for the time being? The default one doesn't seem exhaustive enough. |
@dipanjanS Here is a code snippet that transforms a pandas time series to a luminol time series. I hope it helps. import pandas as pd
import numpy as np
import luminol
from luminol.modules.time_series import TimeSeries
from luminol.utils import to_epoch
# generate random time series in pandas
rng = pd.date_range('1/1/2011', periods=72, freq='H')
ts = pd.Series(np.random.randn(len(rng)), index=rng)
# transform index values to epoch time
ts.index = ts.index.map(lambda d: to_epoch(str(d)))
lts = TimeSeries(ts.to_dict()) |
I am interested in your module, however I noticed that it doesn't support Pandas dataframes out of the box. Would you mind explaining the reasoning behind this? Also - I could potentially add this capability. However, I am trying to understand any potential pitfalls.
Thanks in advance. Great work.
The text was updated successfully, but these errors were encountered: