Python script that converts IB Third-Party TradeLog into .csv format.
IB .tlg file turns into two dataframes with trades and executions 👇
The output can be further used to analize your trades or use trade data with other tools like excel and google docs.
I use the script to convert executions into trades to use in other scripts for per-trade analytics.
pandas
for creating table-like dataframes to store executions and tradestkinter
for simple file dialogpathlib
for cross-platform file path detection
Download the TradeLog .tlg file from IB.
Run the script tradelog_IB.py
and choose the file. On the output you get two dataframes with with data and .csv file with trades.
CSV will be created in the same folder the script is ran from.