Nixtla / nixtla

TimeGPT-1: production ready pre-trained Time Series Foundation Model for forecasting and anomaly detection. Generative pretrained transformer for time series trained on over 100B data points. It's capable of accurately predicting various domains such as retail, electricity, finance, and IoT with just a few lines of code 🚀.
https://docs.nixtla.io
Other
1.91k stars 151 forks source link

TimeGPT exogenous variables #371

Closed PeterMa1 closed 1 week ago

PeterMa1 commented 1 month ago

Hi, i am trying to add exogenous variables to timegpt forecast. However, i am getting the following errors: x_cols = X_df.drop(columns=["unique_id", "ds"]).columns.to_list() AttributeError: 'Index' object has no attribute 'to_list'.

Does anyone else encounter similar problems?

wpdonders commented 1 month ago

You are trying to use the to_list() method on a Pandas Index object that you returned by accessing the columns attribute of a pandas DataFrame. However, your Index object does not appear have such a method. What pandas version are you using?

PeterMa1 commented 1 month ago

Hello, i am using pandas: 0.23.4. and python: 3.7.0.final.0 python-bits: 64 will any of these cause the problem?

elephaint commented 1 month ago

I think to_list() was only added in pandas 0.24. So for your version, you should use tolist(). However, it's probably best to just update pandas to the latest version, to avoid further issues.

Does this fix your issue?

github-actions[bot] commented 1 week ago

This issue has been automatically closed because it has been awaiting a response for too long. When you have time to to work with the maintainers to resolve this issue, please post a new comment and it will be re-opened. If the issue has been locked for editing by the time you return to it, please open a new issue and reference this one.