ERC (equal risk contribution) Portfolio is a C++ library for deriving equal risk distributed portfolios. It implements the cyclical coordinate descent algorithm by Griveau-Billion, Richard and Roncalli. This is the paper.
Make sure you have the Eigen library installed.
Clone this repo to your local machine using https://github.com/mariosgeorgiou/ERCPortfolio
.
cd src
make ercsolver
./ercsolver correlation-matrix-file
where correlation-matrix-file
is a file containing the correlation matrix in space separated values.
The library currently implements the non-optimized version of the algorithm where in each iteration the volatility of the portfolio is recomputed from the risk contribution.
- Optimize running time.
- Create complex tests.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.