Exponential position sizer
Position size that rises with a momentum and volume score, from 0.05 up to the cap. Not a buy or sell signal.
Each bar, the indicator scores momentum from 0 to 10 using four checks: whether returns are accelerating, whether short and mid-term log returns both point up, whether volume is above its recent average, and whether the 14-bar ATR is expanding. The score picks one of five size tiers (base size times 0.5, 1, 2, 3 or 5), scaled by a compounding factor from 1 to 5 that climbs when the score rises and drops on sharp falls. The result is clamped between 0.05 and max_size. Despite the name, it is a stepped sizing rule, not an exponential curve.
How to read it
- The line sits in its own pane below the price, between 0.05 and the cap (1.0 by default).
- It is a sizing value and does not track the price, so read its steps and level rather than a direction.
- A step up means the score reached a higher band (2, 4, 6 or 8 points out of 10) or the compounding factor grew.
- A line stuck at 0.05 means the score stayed low. A line pinned at the cap means strong momentum with the factor built up.
What it outputs
- Position size
- Size value for each bar, from 0.05 up to max_size. A sizing number, not a price, and it does not follow the close.
Settings
- base_size
- Scales every size tier (base times the factor times 0.5, 1, 2, 3 or 5). Raising it lifts the whole line. Low values push the quiet tiers onto the 0.05 floor, so they look alike. Negative values are not meaningful.
- max_size
- Caps every tier from above. Raising it lets strong-momentum bars reach higher sizes. Lowering it flattens the top of the line at that value. Any cap under 0.05 is overridden by the floor, so the line sits at 0.05.
Pitfalls
- The name says exponential, but the sizing is stepped tiers times a compounding factor from 1 to 5. The factor climbs on bars where the score rises, so the same bar can show a different size depending on the path into it.
- Volume and ATR points add to the score whichever way price moves, so a heavy-volume sell-off can hit the cap. The size has no direction and barely correlates with the close, so pair it with a trend filter.
- Until ATR(14) and the return history fill, the output is just base_size. After that it never drops below 0.05, so it never sizes to zero.