pmorissette / bt

bt - flexible backtesting for Python
http://pmorissette.github.io/bt
MIT License
2.22k stars 425 forks source link

FutureWarning: Behavior when concatenating bool-dtype and numeric-dtype arrays is deprecated #412

Open posidonius opened 1 year ago

posidonius commented 1 year ago

FutureWarning: Behavior when concatenating bool-dtype and numeric-dtype arrays is deprecated; in a future version these will cast to object dtype (instead of coercing bools to numeric values). To retain the old behavior, explicitly cast bool-dtype arrays to numeric dtype.

This warning is caused by the following line(s) in backtest.py:

new = pd.concat([empty_row, old])