Post

Automate your trading strategies in Python How to build your first trading bot: (a thread)
How To Make A Trading Bot with Python
$ python backtest.py 2023-01-01 2023-12-30
==================Backtest report==============================
* Start date: 2023-01-01 00:00:00
* End date: 2023-12-30 00:00:00
* Number of days: 363
* Number of runs: 4357
==================Portfolio overview=====================
* Number of orders: 90
* Initial balance: 400.0000 EUR
* Final balance: 464.3659 EUR
* Total net gain: 64.3659 EUR
* Total net gain percentage: 16.0915%
* Growth rate: 16.0915%
* Growth 64.3659 EUR
==================Positions overview=====================
PositionAmountPending amountCost (EUR)Value (EUR)Per
EUR464.3660464.366464.366100
==================Trades overview===================
* Number of trades closed: 45
* Number of trades open: 0
* Percentage of positive trades: 31.11111111111111%
* Percentage of negative trades: 68.88888888888889%
* Average trade size: 109.6916 EUR
* Average trade duration: 123.28888888888889 hours
.... All trades overview
Scan to get the app
Don't miss what's happening
People on X are the first to know.