AI4Finance-Foundation / AI4Finance-Foundation/FinRL
backtest_plot raises error due to Pyfolio package. file: finrl/applications/stock_trading/ensemble_stock_trading.py
- Dominant language
- Jupyter Notebook
- Stars
- 16.3k
- Forks
- 3.5k
- PR merge metrics
- No merged PRs in 30d
Description
Hi, it give an error like below in backtest_plot metthod, when i run finrl/applications/stock_trading/ensemble_stock_trading.py file,
I install all environment like setup.py and requirements.txt
i think this error is related with pandas version but , if back to old version get an error for every library Can Aynoone re-run with correct libraries version and fix all libraries.
Traceback (most recent call last):
File "C:\Users\Onec\Desktop\ömer\FinRL-master\finrl\applications\stock_trading\ensemble_stock_trading.py", line 195, in
main()
File "C:\Users\Onec\Desktop\ömer\FinRL-master\finrl\applications\stock_trading\ensemble_stock_trading.py", line 186, in main
backtest_plot(
File "C:\Python310\lib\site-packages\finrl\plot.py", line 96, in backtest_plot
pyfolio.create_full_tear_sheet(
File "C:\Python310\lib\site-packages\pyfolio\tears.py", line 201, in create_full_tear_sheet
create_returns_tear_sheet(
File "C:\Python310\lib\site-packages\pyfolio\plotting.py", line 54, in call_w_context
return func(*args, **kwargs)
File "C:\Python310\lib\site-packages\pyfolio\tears.py", line 496, in create_returns_tear_sheet
plotting.show_perf_stats(returns, benchmark_rets,
File "C:\Python310\lib\site-packages\pyfolio\plotting.py", line 648, in show_perf_stats
for stat, value in perf_stats[column].iteritems():
File "C:\Python310\lib\site-packages\pandas\core\generic.py", line 5989, in __getattr__
return object.__getattribute__(self, name)
AttributeError: 'Series' object has no attribute 'iteritems'
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.