airborne.jl
AirBorne a complete algorithmic trading framework in Julia.
Science Score: 44.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.0%) to scientific vocabulary
Keywords
Repository
AirBorne a complete algorithmic trading framework in Julia.
Basic Info
- Host: GitHub
- Owner: JuDO-dev
- License: mit
- Language: Julia
- Default Branch: dev
- Homepage: http://judo.dev/AirBorne.jl/
- Size: 6.05 MB
Statistics
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 8
- Releases: 0
Topics
Metadata Files
README.md
AirBorne
Welcome to the AirBorne a complete algorithmic trading framework for Julia.
This module simplifies algorithmic trading by providing a set of ready to use backtesting algorithms, templates for common trading strategies, full ETL (Extract Transform Load) data pipelines with datasources such as NASDAQ and Yahoo Finance. The philosophy of the design of this module is best represented by the diagram below.
Note: AirBorne still does not have the functionality to operate as live server nor interact with third party broker APIs, however a seamless transition between trading strategies in AirBorne backtesting engines is one of the goals of the project and shall be prioritized in due course.
How to use AirBorne
Installation
Airborne is a %100 Julia native package, so making use of it is as simple as installing a module.
julia
using Pkg;
Pkg.add(url="https://github.com/JuDO-dev/AirBorne.jl#dev");
Usage
There are many examples through our documentation from how to define trading strategies for a backtesting engine using Model Predictive Control to how to perform simple queries to fetch ticker data using the ETL and store it for later use.
Nonetheless a very brief example on some of the functionalities of this package will be shown here.
Data Pipeline Functions
```julia
Fetch data from NASDAQ API, returning its screener data (https://www.nasdaq.com/market-activity/stocks/screener)
using AirBorne.ETL.NASDAQ: screener tickers_df = screener()
Fetch OHLCV data from YahooFinance on Apple and Google tickers
using AirBorne.ETL.YFinance: getinterdaydata
using Dates: DateTime,datetime2unix
unix(x) = string(round(Int, datetime2unix(DateTime(x))))
data = getinterdaydata(["AAPL","GOOG"], unix("2017-01-01"), unix("2022-01-01"))
first(data,4) # Display first 4 rows
```

Backtesting
Backtesting has nuances, consists of testing a trading strategy using past data and looking closer one needs to consider many things such as:
- In which format and over which times an exchange provides data?
- How is an asset priced in the market, would it depend on the order size? There are many theories around this, which one to use?
- Can orders be unsuccessful? How an order be executed partially?
- What are the fees for a broker broken down?
- How is the simulation executed?
All of the points above are dealt thoroughly in AirBorne's documentation.
Observe how easily and in few lines one can do 5 years of backtesting using the data extracted in the previous example, using AirBorne's Discrete Event Driven Simulation (DEDS) engine along with our Static Market model whilst implementing a Markowtiz mean variance strategy.
```julia
Using the data from Yahoo Finance, apply a Mean-Variance Markowitz strategy
using AirBorne.Engines.DEDS: run using AirBorne.Markets.StaticMarket: executeorders!, exposedata using AirBorne.Strategies.Markowitz: initialize!, trading_logic! using Dates: DateTime
Preselect the trading events (trading events can be added on the fly during strategies, this step is optional)
evaluationEvents = [TimeEvent(t, "data_transfer") for t in sort(unique(data.date); rev=true)]
Indicate that the market will provide data incrementally to the strategy
myexposedata(context,data) = expose_data(context,data; historical=false)
Run backtest
context = run(data, initialize!, tradinglogic!, executeorders!, myexposedata; audit=true, max_date=DateTime(2022, 1, 1), verbose=true, initialEvents=evaluationEvents)
context contains the portfolio at the end of the backtest s
portfolioatendoftradingsimulation = context.portfolio currentaccountsatendoftrading_simulation = context.accounts
If audit is set to true during the simulation it also contain snapshots
snapshotofportfolioattheendofeachsimulation_event = context.audit.portfolioHistory
Visualize portfolio value over time
using AirBorne.Structures: summarizePerformance
using Plots: plot
results = summarizePerformance(data, context) # Use the audit history to ana
plot(results.date, results.dollarValue, title="Markowtiz Strategy: Porfolio Dollar Value", label="value", xlabel="date", ylabel=" Portfolio Value - USD", linewidth=3)
```

Want new features or questions answered?
We are thrilled to know that you want our package to grow, there are a couple of ways for you to suggest (and event put forward) new features.
- Raise an issue: We will look into request among the issues and pro
- Put a merge request: We are thrilled to review merge request with new features, we have an CI pipeline in place that will let you know if any of your MRs needs tinkering, from checking for typos and code linting to unit tests.
Request for definitions in the documentation are also welcome! It is very important for the project to establish a common unambiguous ground for concepts. This includes being able to define what is a portfolio, what is an investor, a broker and an exchange. Therefore the documentation in this package will include definitions for all the financial elements modelled in this package and more backed up with references to reliable sources. If you don't find something or think some of the definitions can be improved raise an issue, we shall be happy to abide!
Owner
- Name: JuDO-dev
- Login: JuDO-dev
- Kind: organization
- Repositories: 10
- Profile: https://github.com/JuDO-dev
Julia for Dynamic Optimization
Citation (CITATION.cff)
cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: Kerrigan
given-names: Eric
- family-names: Nita
given-names: Lucian
- family-names: Castro
given-names: Bruno
title: "AirBorne: A Julia Algorithmic Trading Framework"
repository: "https://github.com/JuDO-dev/AirBorne.jl/"
url: "https://github.com/JuDO-dev/AirBorne.jl/"
version: 0.0.1
date-released: 2023-09-14
contact:
- affiliation: "Imperial College London"
family-names: Castro
given-names: Bruno
- affiliation: "Imperial College London"
family-names: Kerrigan
given-names: Eric
GitHub Events
Total
Last Year
Dependencies
- actions/checkout v2 composite
- codecov/codecov-action v3 composite
- julia-actions/cache v1 composite
- julia-actions/julia-buildpkg v1 composite
- julia-actions/julia-docdeploy v1 composite
- julia-actions/julia-processcoverage v1 composite
- julia-actions/julia-runtest v1 composite
- julia-actions/julia-uploadcodecov latest composite
- julia-actions/setup-julia v1 composite
- actions/checkout v3 composite
- julia-actions/setup-julia latest composite
- actions/checkout v3 composite
- crate-ci/typos v1.14.12 composite
- JuliaRegistries/TagBot v1 composite
- julia 1.8.5-bullseye build