As soon as you will get into pretty complex derivatives, for example, you will need to generate correlated assets for pricing purposes. Example of such derivatives can be: Basket options Rainbox options Moutain ranges (created by Société Générale) The most complex amongst these derivatives cannot be priced using closed form formulae, Monte Carlo simulations are … Continue reading How to Generate Correlated Assets and Why?

# python

# Speed Execution Benchmark on Monte Carlo

Today I will try to benchmark the execution speed of several programming languages on a Monte Carlo example. This benchmark involves VBA, C++, C#, Python, Cython and Numpy vectorization. I will try to add progressively other programming languages so that this article will be more thorough. Execution environment All the chunks of code have been … Continue reading Speed Execution Benchmark on Monte Carlo

# How to get Implied Volatility?

In this article, I will introduce what is implied volatility and several methods to find it. Here are the points I will try to cover: What is Implied Volatility? Dichotomy Method Newton Raphson Method Example in Python with a set of option prices Models Conclusion Implied Volatility Historical volatility and implied volatility, what is the … Continue reading How to get Implied Volatility?

# Barrier option pricing with Monte Carlo

In this short article, I will apply Monte Carlo to barrier option pricing. Here are the points I am going to tackle: Quicker barrier options reminder Pros and cons of Monte Carlo for pricing Steps for Monte Carlo Pricing Up-and-Out Call pricing example Conclusion and ideas for better performance Barrier options Before entering in pricing … Continue reading Barrier option pricing with Monte Carlo

# Backtest a trading strategy in Python

In this article, I will introduce a way to backtest trading strategies in Python. All you need for this is a python interpreter, a trading strategy and last but not least: a dataset. A complete and clean dataset of OHLC (Open High Low Close) candlesticks is pretty hard to find, even more if you are … Continue reading Backtest a trading strategy in Python

# Monte Carlo Simulations of an asset with Black & Scholes dynamic

Introduction This first and basic article will show how to simulate a security following the Black & Scholes dynamic : $latex \frac{dS_t}{S_t} = \mu dt + \sigma dB_t$ When solving this stochastic differential equation with Ito, you finally obtain: $latex S_T = S_0 e^{(\mu - \frac{\sigma ^2}{2})T + \sigma B_T}$ The browian motion $latex B_T$ … Continue reading Monte Carlo Simulations of an asset with Black & Scholes dynamic