Trading the Breaking

Trading the Breaking

Share this post

Trading the Breaking
Trading the Breaking
[WITH CODE] Testing: Synthetic scenarios
Alpha Lab

[WITH CODE] Testing: Synthetic scenarios

Learn how to generate realistic financial time series that mimic market behavior while maintaining flexibility.

𝚀𝚞𝚊𝚗𝚝 𝙱𝚎𝚌𝚔𝚖𝚊𝚗's avatar
𝚀𝚞𝚊𝚗𝚝 𝙱𝚎𝚌𝚔𝚖𝚊𝚗
Mar 05, 2025
∙ Paid
7

Share this post

Trading the Breaking
Trading the Breaking
[WITH CODE] Testing: Synthetic scenarios
1
Share

Table of contents:

  1. Introduction.

  2. Preliminaries and notation.

  3. Input data and preprocessing.

  4. Cholesky decomposition.

  5. Generation of random returns.

  6. Incorporating the original data via convex combination.

  7. Implementation of the method.


Introduction

Anyone who has been talking to me for a while knows that there is one field that I have explored quite a bit. I am referring to synthetic data. Yes, I know, the same one. Why? Imagine you’re a Hollywood director. Your mission? Shoot a sequel to The Matrix that’s faithful to the original’s vibe but with fresh chaos. Synthetic time series are your CGI: they mimic real-market dynamics while letting you control the chaos. In other words, you can create specific scenarios with laboratory conditions.

In many scientific fields—from econometrics to engineering—it is often necessary to simulate time series data that replicate the statistical dependencies found in real data. In our field as well, because synthetic data is used for:

  • Stress testing.

  • Risk assessment.

  • Validating statistical models.

The method I share with you today is especially suited for generating sequences that mimic both the volatility and trends of historical data while preserving their empirical correlation structure.

The approach uses several key mathematical tools:

  • Empirical correlation matrix captures the relationships between variables.

  • Cholesky decomposition transforms independent random draws into correlated returns.

  • A multiplicative compounding process models the dynamics of time series.

  • Finally, a convex combination of the synthetic series and the original data allows for a controlled balance between historical fidelity and randomness.

Here a sample of what we are going to build:

Before starting with the preliminaries, remember to subscribe! 😊

This post is for paid subscribers

Already a paid subscriber? Sign in
© 2025 Quant Beckman
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share