You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
timestamps = prices.index.to_series().loc[start:]
# Check if the last day doesn't have data yet
# Like if it was early in the morning
if not timestamps[-1] in prices:
timestamps = timestamps[:-1]
That if statement will always pass. When using the in keyword with DataFrames it only checks the columns of the DataFrame. I think what you were trying to do is check the index of the DataFrame.
I am not really sure why you are doing this. You grab the timestamps from the prices and then you proceed to check if timestamp[-1] is not in prices (which will never happen).
The text was updated successfully, but these errors were encountered:
@z123 Thanks I'm not really sure why I did that either. I have a hunch timestamps was probably calculated a different way at some point. Anyways, I'll fix that, thanks!
There seems to be a bug in this block of code.
See https://github.com/Emsu/prophet/blob/master/prophet/backtest.py#L64-L69.
That if statement will always pass. When using the
in
keyword with DataFrames it only checks the columns of the DataFrame. I think what you were trying to do is check the index of the DataFrame.I am not really sure why you are doing this. You grab the timestamps from the prices and then you proceed to check if timestamp[-1] is not in prices (which will never happen).
The text was updated successfully, but these errors were encountered: