admin

Financial Data Structures for Machine Learning Applications

Today we will be exploring the financial data structures as discussed in Advances in Financial Machine Learning by Prof. Marcos Lopez de Prado [2018]. We will create four standard price and volume bars commonly used in financial machine learning within academic literature: time bars, tick bars, volume bars and dollar bars.

In this tutorial we are learning how to construct these standard bars in Python from raw trade information on a given product, here we are using Commonwealth Bank of Australia (CBA) equities trading information from my CommSec brokerage.

Modelling Stock Volatility with Ornstein-Uhlenbeck process

Understanding and modelling volatility accurately is of utmost importance in financial mathematics. The emergence of volatility clustering in financial markets can make estimating volatility very difficult.

Here we explain how to use a stochastic model called Ornstein-Uhlenbeck process to model volatility. We explain the mathematics of using a method called Maximum Likelihood Estimation (MLE) to estimate the parameters of the Ornstein-Uhlenbeck process based on S&P500 historical/realised volatility.

Brownian Motion for Financial Mathematics

In this tutorial we will investigate the stochastic process that is the building block of financial mathematics. We will consider a symmetric random walk, scaled random walk and browian motion. The mathematic notation and explanations are from Steven Shreve’s book Stochastic Calculus for Finance II.
Important properties of brownian motion is that it is a martingale Markovprocess and that it accumulates quadratic variation at rate one per unit time.
Note: Quadratic Variation is perhaps what makes Stochastic Calculus so different from Ordinary Calculus.

Delta Hedging using Black-Scholes

Full worked example of the impact of delta hedging european options. Implied Volatility Create functions to appply to pandas dataframes to calculate specific adjustments to be made during delta hedging. Create Dynamic Hedging results dataframe to append rows to. Create simulations of underlying stock prices using Geometric Brownian Motion (GBM) over time. Build up delta hedging dataframe with specific factors:  delta total delta positions  …

Delta Hedging using Black-Scholes Read More »

Value at Risk (VaR) and Conditional VaR (CVaR)

Ever wondered what Value at Risk (VaR) or Conditional Value at Risk (CVaR) is and how it can help you?

In this tutorial we break down the basics of these two concepts and explain three methodologies for calculating VaR. We will begin to implement these slowly with Python!

Historical Volatility Cones

To truly be an effective options trader it’s essential that you understand volatility. After all, having a sense of whether an option is “cheap” or “expensive” should help in your option strategy selection. For the most part, traders focus on two types of volatility, implied volatility and historical volatility. This article concentrates on the latter.