- Published on
Bet Sizing
Bet Sizing
This chapter argues that, much like in poker, bet sizing is a critical component of a profitable investment strategy. An ML algorithm with high predictive accuracy can still lose money if its bets are sized improperly. The chapter introduces several methods for determining position size, moving from simple heuristics to dynamic, probability-based models.
Strategy-Independent Bet Sizing Approaches
The text introduces three preliminary methods for bet sizing:
Gaussian CDF: This method computes the net number of concurrent long and short bets () active at time . A mixture of two Gaussians is fit to the distribution of . The bet size is then determined by the CDF of this mixture, which scales the bet based on how extreme the current signal concurrency is.
- Equation:
- Equation:
Budgeting Approach: The bet size is a simple fraction of the maximum number of concurrent bets ever observed, scaling the position to ensure the full size is not reached prematurely.
- Equation:
Meta-Labeling: Use the probability of a false positive (derived from a meta-model, as discussed in Chapter 3) to determine the bet size. This leads to the more general method of using predicted probabilities.
Bet Sizing from Predicted Probabilities
This is the core method, which converts a model's predicted probability (confidence) into a bet size.
Binary Case (Labels ): We test the prediction's confidence against the null hypothesis . The bet size is the CDF of the resulting -score.
- Test Statistic:
- Bet Size: , where is the Standard Normal CDF.
Multi-Class Case (e.g., ): We test the probability of the most likely outcome () against the null hypothesis of pure chance ().
- Test Statistic:
- Bet Size: . Here, is the side (e.g., -1 or 1) and the term is the magnitude of the bet, scaled between .
Bet Sizing Refinements
These methods are used to reduce excess turnover and trading costs.
- Averaging Active Bets: Instead of overriding a position when a new signal arrives, this method averages the bet size across all signals that are still active (i.e., have not yet hit a barrier from the triple-barrier method).
- Size Discretization: To prevent "jitter" (many small, inefficient trades) from the averaging process, the final bet size is discretized to a specific step size .
- Equation:
Dynamic Bet Sizes and Limit Prices
This is an advanced method that dynamically adjusts the bet size as the market price fluctuates relative to the forecasted price .
Sizing Function (Sigmoid): The target position is determined by a sigmoid function, where the input is the divergence between the forecast and the current price ().
- Equation:
- Property: As the market price approaches the forecast (), the divergence , and the bet size . This automatically "realizes gains."
- Calibration: The width can be calibrated:
Limit Price: This method also allows for the calculation of a breakeven limit price for the order, preventing the algorithm from realizing losses as it dynamically adjusts.
- Inverse Function:
Alternative (Power Function): A power function can also be used, which offers different curvature properties.
- Equation:
API reference
RiskLabAI implements these in Python and Julia (signatures auto-generated from the package source):
| Python | Julia |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| |