https://github.com/clojure-finance/clojure-backtesting
Backtesting framework for quantitative investing/trading
https://github.com/clojure-finance/clojure-backtesting
Last synced: 8 months ago
JSON representation
Backtesting framework for quantitative investing/trading
- Host: GitHub
- URL: https://github.com/clojure-finance/clojure-backtesting
- Owner: clojure-finance
- License: mit
- Created: 2020-09-05T00:43:37.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-06-26T03:42:46.000Z (over 2 years ago)
- Last Synced: 2025-05-07T20:37:10.143Z (8 months ago)
- Language: Clojure
- Homepage: https://clojure-finance.github.io/clojure-backtesting-website/
- Size: 17 MB
- Stars: 35
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Clojure Backtesting Library
A backtesting framework for quantitative investing and trading.
## Requirements
- Java
- Clojure Leiningen
A good [tutorial](https://ericnormand.me/guide/how-to-install-clojure) about installing the above softwares. **Remember to reboot the system after changing the environment path every time.**
## How to install
1. ### Lein REPL
*No need to install extra softwares. **Recommended for new users.***
1. Clone the repo and decompress.
2. Under the directory, run below command in the terminal to start a Lein REPL.
`lein repl`
3. Run the examples in the [`/examples`](/examples) folder line by line in the REPL.
2. ### Gorilla REPL
*Can save strategies in notebooks.*
every time you open Gorilla REPL, run
```
lein gorilla
```
3. ### Try it out online
*Only try out the basic APIs with a small dataset.*
[Online interactive notebook](https://mybinder.org/v2/gh/clojure-finance/clojure-backtesting/binder)
## How to use
1. Go through every examples in the [`/examples`](/examples) folder to get a basic understanding of the system.
2. Documentations for every detailed APIs can be found [here](https://clojure-finance.github.io/clojure-backtesting-website/#part-ii-api-documentation).
3. Learn to use the APIs to write your own strategy!
## Update
Make sure you have the latest version of the code installed by running after each clone:
```
make add_kernel
```
## Report bugs
As we are still working to fully debug the code and create more examples, feel free to report issues in the repository and we appreciate your kind support.
## Development
To start an interactive prompt where you can enter arbitrary code to run in the context of your project:
```
lein repl
```
To run the default `:main` set in `project.clj`:
```
lein run
```
To run all tests written in the `test` namespace:
```
lein test
```