Skip to content
All library documents

Fixed-Risk Position Sizing for Spread Betting Backtests

Article Quant Q&A · Author: Oliver P

Summary

The document describes a fixed-risk position-sizing approach used in spread betting. The trader chooses a fraction of account equity to risk, measures the distance between entry and stop in points or pips, and divides the cash risk allowance by that distance to determine the stake per point. The example uses a £1,000 account, a 1% risk allowance, and a stop 10 points from entry, yielding a stake of £1 per point.

The practical question is how to represent this calculation inside a backtesting framework, with the author mentioning a Python package and being open to alternatives. No implementation or framework recommendation is supplied, so the document is a sizing example and an integration question rather than a worked backtest. It also does not discuss gaps, slippage, fees, changing equity, or whether a stop will execute at its intended price; these can make realized losses differ from the planned risk.

Key ideas

  • Set a cash risk budget as a chosen fraction of account equity.
  • Divide the risk budget by the entry-to-stop distance to calculate stake per point or pip.
  • The example illustrates fixed-risk sizing for a spread bet with a £1,000 account and a 10-point stop.
  • A backtest must represent position sizing within its strategy or broker model.
  • The document does not provide implementation details or account for execution effects.

Tags

Full text
# Spread betting risk management in backtesting in Python


# Spread betting risk management in backtesting in Python












My background is in Spread Betting. I know how to calculate my position size based on how far away my stop is from my entry, I calculate the amount per pip so that I only ever risk a fixed percentage of my account on any one trade e.g. 1%.

So say my account is £1,000, 1% is £10 (The amount I want to risk on the trade). The stop, which for simple maths is 10 pips/points away. £10 / 10points is £1 per pip/point.

I'm new to backtesting frameworks and have chosen the "Backtesting" package as my first one to give a go: https://pypi.org/project/Backtesting/. I'm open to other frameworks/packages such as Zipline.

What suggestions do you have as to what framework this would be easiest with, and/or examples of how to do it whether or not that's with the Backtesting package.

(Just to clarify, I have written my own custom live trading system which does all this but only for live trading. Now I want to specifically implement it within a strategy backtest framework.)

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.