Introduction¶
deepdow
is a framework that focuses on portfolio optimization via end-to-end deep learning. Its goal is to
facilitate research of networks that perform weight allocation in one forward pass.
Name¶
The name of the packages is inspired by the father of technical analysis—Charles Dow.
Traditional portfolio optimization¶
As described by Markowitz [MARK1952], portfolio optimization is commonly divided into 2 separate stages:
Creation of beliefs about the future performances of securities
Finding optimal portfolio given these beliefs
One extremely popular example of this two stage paradigm is:
Estimation of expected returns \(\boldsymbol{\mu}\) and covariance matrix \(\boldsymbol{\Sigma}\)
Solving a convex optimization problem, e.g. \(\boldsymbol{\mu}^T \textbf{w} - \gamma \textbf{w}^T \boldsymbol{\Sigma} \textbf{w}\) such that \(\textbf{w} > 0\) and \({\bf 1}^T \textbf{w}=1\)
Commonly, these two steps are absolutely separated since they require different approaches
Predictive modeling (statistics + machine learning)
Objective function and constraints design
Not surprisingly, one needs to use totally different tools. Below are some examples from the Python ecosystem.
numpy
,pandas
,scikit-learn
,statsmodels
,tensorflow
,pytorch
, …cvxpy
,cvxopt
,scipy
, …
Why DeepDow different?¶
deepdow
strives to merge the above mentioned two steps into one. The fundamental idea is to construct
end-to-end deep networks that input the rawest features (returns,
volumes, …) and output asset allocation. This approach has multiple benefits:
Hyperparameters can be turned into trainable weights (i.e. \(\gamma\) in 2nd stage)
Leveraging deep learning to extract useful features for allocation (rather than just prediction)
Single loss function