Timeseries Analysis

A wide range of financial statistics is calculated based on a timeseries of portfolio value, historical stock prices or a series of historical returns. The main statistics are: Total Return, Annualised Return, Annualised Volatility, Annualised Upside Vol., Annualised Downside Vol., Sharpe Ratio, Omega Ratio, Calmar Ratio, Gain to Pain Ratio, Sorino Ratio, 5% CVaR, Annualised 5% CVaR , Max Drawdown , Avg Drawdown , Avg Drawdown Duration, Best Return, Worst Return, Avg Positive Return, Avg Negative Return, Skewness, Kurtosis and Kelly Value.

Charting

To visualize financial data more easily, various plotting tools are available. The supported chart types include specialized financial line charts, the box plot chart, the univariate distribution chart, the histogram chart, the univariate kernel density estimate plot, heatmaps, underwater charts, and many more. They all can be surrounded by various decorators, such as moving average, point emphasis, legend or bar values, depending on the desired presentation form.

Portfolio Construction

The Library implements number of portfolio constructions algorithms. It supports the traditional Markowitz mean-variance optimization portfolios such as Minimum Variance Portfolio, Market Portfolio and Efficient Frontier optimization. The available models go beyond Markowitz and offer other types of portfolios. For example: Kelly Portfolio or Max Excess Return Portfolio. Other portfolio types can be implemented as an extension of a simple interface.

Research on Investment Strategies

Backtesting capabilities of the library allow creation and testing of investment strategies on historical data. Thanks to the architecture based on interfaces, it is easy to implement custom indicators and to use them as a part of a strategy. A researcher receives feedback in the form of generated documents containing statistics, charts, rolling window and in-sample out-of-sample tests, which help in developing robust strategies. The Library supports the process of model tuning – a set of testing tools allows choosing the best parameters for an alpha model. The tools for backtest overfitting prevention reinforce overall research process.

Studies, Market Indicators and Analysis

One of the virtues of the Library is its flexibility and convenience when using in implementing custom studies. The project provides a set of tools, which can be used in a way depending on analyst/researcher need. It could range from building custom market indicators through analyzing patterns to studies of trading models.