Using C++ for High-Performance Backtesting
Summary
The document addresses whether C++ can be used to build a backtester and whether existing implementations are available. Its answer is that backtesting software can be written in any programming language, including C++, and that public C++ examples and projects exist.
The main rationale offered for C++ is performance: compiled implementations can run backtests quickly. The discussion is brief and does not compare specific libraries, describe their features, or weigh development effort and flexibility against speed. It therefore supports considering C++ when computational performance matters, but gives no benchmark evidence or basis for choosing a particular tool.
Key ideas
- A backtester can be implemented in C++ or other programming languages.
- C++ backtesting projects are publicly available.
- High execution performance is presented as a reason to choose C++.
- The document does not compare libraries or quantify performance.
Tags
Full text
# Is C++ suitable for writing backtests # Is C++ suitable for writing backtests I'm looking for a library like BackTrader or platform that is written in C++ for backtesting. Is C++ a good choice to write a backtester and are any available? ## Answer by Bob Jansen (score 2) https://quant.stackexchange.com/a/75593 You can write a Backtester in any language you want and quite a few people did so in C++ and made the source code available: https://github.com/topics/backtesting?l=c%2B%2B A reason to perform backtests with code written in C++ is that it can achieve very good performance.
Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.