2025-05-17 08:33:11 -05:00
2023-05-10 07:54:28 -05:00
2024-10-31 15:13:07 -05:00
2023-05-24 15:58:59 -05:00
2023-05-21 10:53:26 -05:00
2023-05-24 16:31:13 -05:00
2025-05-17 08:33:01 -05:00
2025-05-17 08:58:08 -05:00
2023-05-20 19:09:41 -05:00
2023-05-24 15:58:59 -05:00
2023-05-24 15:58:59 -05:00
2023-05-24 15:58:59 -05:00
2023-05-12 19:36:03 -05:00

autotrader

[WARNING]: There are still many bugs to be fixed, this software is not ready to be used for live trading. PRs and bug fixes welcome!

If you still feel like importing the library into your project, I highly recommend vendoring it (copying it directly to the folder).

Autotrader is a forex quantitative trading engine I developed in two weeks using Go. The unique backtesting simulations runs a user-designed trading algorithm against historical market data. The simulation accounts for brokerage fees, hedging, leverage, market orders, limit orders, stop orders, and more. Once a reliable strategy has been identified, the user can run the trading algorithm they created on their live brokerage account.

Autotrader inserts layers of abstraction all the way down from the implementation of the trading strategy to the orders and positions maintained by the brokers over their JSON REST APIs. All financial algorithms and data structures used in this project were developed from scratch, including a time series table inspired by the NumPy Python data science library.

The following page is a report generated by Autotrader when backtesting a naive SMA crossover strategy using realtime Forex market data:

Graph of live trades as executed by the strategy.

Return on investment of the strategy plotted over time.

Profitability graph of the strategy.

License

Zero-clause BSD (0BSD)

Description
Forex automated trading algorithm backtesting and trading engine (with partial Oanda brokerage support)
Readme 0BSD 281 KiB
Languages
Go 100%