Riskfolio-Lib
Quantitative Strategic Asset Allocation, Easy for Everyone.
Description
Riskfolio-Lib is a library for making quantitative strategic asset allocation or portfolio optimization in Python made in Peru 🇵🇪. It is built on top of cvxpy and closely integrated with pandas data structures.
Some of key functionalities that Riskfolio-Lib offers:
-
Portfolio optimization with 4 objective functions:
- Minimum Risk.
- Maximum Return.
- Maximum Utility Function.
- Maximum Risk Adjusted Return Ratio.
-
Portfolio optimization with 11 convex risk measures:
- Standard Deviation.
- Semi Standard Deviation.
- Mean Absolute Deviation (MAD).
- First Lower Partial Moment (Omega Ratio)
- Second Lower Partial Moment (Sortino Ratio)
- Conditional Value at Risk (CVaR).
- Worst Case Realization (Minimax Model)
- Maximum Drawdown (Calmar Ratio)
- Average Drawdown
- Conditional Drawdown at Risk (CDaR).
- Ulcer Index.
-
Risk Parity Portfolio optimization with 8 convex risk measures:
- Standard Deviation.
- Semi Standard Deviation.
- Mean Absolute Deviation (MAD).
- First Lower Partial Moment (Omega Ratio)
- Second Lower Partial Moment (Sortino Ratio)
- Conditional Value at Risk (CVaR).
- Conditional Drawdown at Risk (CDaR).
- Ulcer Index.
-
Worst Case Mean Variance Portfolio optimization.
-
Portfolio optimization with Black Litterman model.
-
Portfolio optimization with Risk Factors model.
-
Portfolio optimization with constraints on tracking error and turnover.
-
Portfolio optimization with short positions and leveraged portfolios.
-
Tools for build efficient frontier for 11 risk measures.
-
Tools for build linear constraints on assets, asset classes and risk factors.
-
Tools for build views on assets and asset classes.
-
Tools for calculate risk measures.
-
Tools for calculate risk contributions per asset.
-
Tools for calculate uncertainty sets for mean vector and covariance matrix.
-
Tools for estimate loadings matrix (Stepwise Regression and Principal Components Regression).
-
Tools for visualizing portfolio properties and risk measures.
Documentation
Online documentation is available at Documentation.
The docs include a tutorial with examples that shows the capacities of Riskfolio-Lib.
Dependencies
Riskfolio-Lib supports Python 3.7+.
Installation requires:
- numpy >= 1.17.0
- scipy >= 1.1.0
- pandas >= 1.0.0
- matplotlib >= 3.3.0
- cvxpy >= 1.0.15
- scikit-learn >= 0.22.0
- statsmodels >= 0.10.1
- arch >= 4.15
Installation
The latest stable release (and older versions) can be installed from PyPI:
pip install riskfolio-lib
Development
Riskfolio-Lib development takes place on Github: https://github.com/dcajasn/Riskfolio-Lib
RoadMap
The plan for this module is to add more functions that will be very useful to asset managers.
- Mean Entropic Risk Optimization Portfolios.
- Add functions to estimate Duration, Convexity, Key Rate Durations and Convexities of bonds without embedded options (for loadings matrix).
- Add more functions based on suggestion of users.
Metadata
Release files for riskfolio-lib 0.0.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| Riskfolio-Lib-0.0.7.tar.gz | 4.0 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| Riskfolio_Lib-0.0.7-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 4.0 MB
Release files / Riskfolio-Lib-0.0.7.tar.gz
| Download URL | Riskfolio-Lib-0.0.7.tar.gz |
|---|---|
| Size | 4.0 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
afb461dcc03160b2513323bfc875c581019322e6aff82f81d887fe3bfe244f9f
|
|
BLAKE2b-256 checksum How to use checksums |
a5435d06df1fb664fb382d917299127cec02712592e64342a97acbbfb6c645b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0.post20201207 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.5
|
Release files / Riskfolio_Lib-0.0.7-py3-none-any.whl
| Download URL | Riskfolio_Lib-0.0.7-py3-none-any.whl |
|---|---|
| Size | 37.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4da5674d65cc8b70449cc69b2187c5462f6555472e672667ca26c99a1ca80b1e
|
|
BLAKE2b-256 checksum How to use checksums |
e58b21aca2d082065d2d7bbc178df1c93228765e2d6586de65c89c03b0451bcf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0.post20201207 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.5
|