LIFO is standard calculation for Mudley Group Rebalancing and Grid trading strategies.
Make sure you have Python 3.7 installed locally.
$ git clone
$ cd cal_profits
$ pip install -r requirements.txt
Enter your api_key, api_secret, subaccount Default exchange is FTX Set your account name (report name)
$ python cal_profits.py
1) match_order.csv
2) remain_order.csv
3) remain_report.csv
4) tradinglog.csv
Last In, First Out LIFO.
1) python
2) numpy
3) pandas
4) pytz
5) ccxt
Mudley Australia