Hello friends and traders!
🔹Introduction
This indicator "Stop-Loss Clustering (Breakouts)" attempts to model trader stop-loss placement logic and identify price areas where a large amount of stop losses might cluster.
The idea is, if stop losses are indeed highly concentrated in a specific area, price extending through that area may produce high-velocity breakout conditions via forced order flow.
I'll cover this topic more thoroughly throughout the description. For now, just know that stop loss location & size data is not publicly available. Any model of their concentration locations is highly assumptive.
However, there's some reasonable academic research we can reference to make worthwhile estimates.
Academic references supporting the concepts discussed are listed at the end of this description. To maintain readability, I won't cite individual statements inline.
🔹The Premise
🔸Liquidity, Behavior, and Stop Cascades
Markets operate through a continuous limit order book, where two fundamental order types interact:
This mechanical interaction drives price movement - incoming order flow consuming available liquidity.
This begs the question.. Does liquidity distribute evenly across the LOB?
If it did: If liquidity were evenly distributed, price impact could be modeled as a relatively smooth function of incoming order flow.
But it doesn’t: Liquidity is unevenly distributed. Academic research supports this claim and, regardless, this is an intuitive conclusion most traders arrive at.
Liquidity forms localized concentrations and gaps.
Liquidity concentrations are commonly referenced as:liquidity shelves, liquidity clusters, liquidity zones.
Liquidity gaps are commonly referenced as: liquidity vacuums, thin book zones.
As a result, identical order flow can produce very different price movements depending on the state of the order book.
Let’s consider an example..
Assume price is trading at $99.
The price levels $100, $101, $102 have resting sell limit order concentrations of 100.
This is where you come in.
You execute a market order buy for 300 size.
Your order first exhausts all sell-side resting order concentrations at the $100 level.
You still have 200 size that needs to be filled, and the ask price has moved from $100 to $101.
Your order will now sequentially exhaust available liquidity at the $101 level, the ask price will increase to $102, and your final 100 size will exhaust the $102 level.
To keep the example simple, we’ll say that your order moved price from $99 to $102, and now the ask price is $103.
But, you still want to accumulate.
The nearest sell-side levels in the LOB are $103, $104, $105.
The $103 level has a sell limit order concentration of 500.
$104 and $105 both have concentrations of 50.
You execute your same market order buy for 300 size.
This time, price doesn’t move.. At all..
Instead, you consumed 300 of the 500 size at $103 with your order, and the level remains a barrier.
Your order was absorbed by available liquidity.
This example demonstrates how price movement depends on available liquidity, not simply the size of incoming orders.
In the first scenario, liquidity was thin and the order walked through multiple price levels, causing price to move quickly.
In the second scenario, a large concentration of resting liquidity absorbed the same order, preventing price from advancing.
🔸Liquidity Does Not Distribute Evenly
Alright, we understand that liquidity doesn’t distribute evenly. And we understand that high concentrations of liquidity can act as price barriers (liquidity shelves) while sparse liquidity can permit rapid price movement - we saw this in our example above.
There’s an important question we should ask next before we move on..
If liquidity distributes unevenly, then where does it tend to cluster? And where does it tend to thin?
Of course, knowing these tendencies provides multi-purpose advantages.
If price approaches a liquidity vacuum - a local block of the order book with thin resting liquidity - rapid price movement can occur without requiring unusually strong aggressive order flow.
If price approaches a liquidity shelf - a local block of the order book with thick resting liquidity - price can stall or contract even if the same level of aggressive order flow that previously moved price continues.
With this in mind, order flow intensity alone does not determine price movement. The distribution of liquidity across surrounding price levels plays a similarly important role.
So, is there any evidence of where liquidity tends to concentrate?
🔸Empirical Observations
Empirical research on limit order books shows that liquidity does not distribute smoothly across the LOB. Instead, depth tends to concentrate at specific price levels, producing irregular profiles with localized peaks in resting liquidity.
These concentrations arise because order placement is not random. Traders frequently anchor decisions to widely observed reference prices such as:
• prior highs
• prior lows
• round numbers
• widely referenced price extremes
Because many traders monitor the same price history, order placement decisions often reference similar price levels.
This concept is simpler than it sounds.
Let’s use market structure traders for example.
Market structure traders frequently reference prior swing highs and swing lows when making decisions about entries, exits, and risk.
A trader entering a long position may place their stop-loss below a recent swing low, reasoning that if price breaks that level, the trade idea is invalidated.
A trader entering a short position may place their stop-loss above a recent swing high for the same reason.
Timeframe price aggregation may differ; however, we’re all looking at roughly the same recent highs and lows when evaluating a chart (structure).
When many traders collectively reference the same prices, orders may accumulate near those levels. This produces localized depth concentrations, which traders refer to as liquidity shelves.
Liquidity shelves act as temporary barriers where the book contains disproportionately large resting liquidity compared to surrounding prices.
🔸Research documenting liquidity clustering includes:
Bourghelle & Cellier (2007), who find that limit orders cluster at prominent price levels (especially round numbers), creating localized depth concentrations that can act as price barriers.
Kavajecz & Odders-White (2004), who demonstrate that prices identified as support or resistance coincide with higher resting limit order depth
These findings suggest that many commonly observed price levels may correspond to real concentrations of liquidity rather than being purely visual artifacts on a chart.
Kavajecz & Odders-White (2004) is an important observation for support/resistance traders!
Kavajecz & Odders-White (2004) show that levels traders commonly call support and resistance often align with areas where more limit orders are resting in the order book.
This suggests a plausible mechanical pathway through which support and resistance levels can emerge!
🔸Liquidity Shelves and Price Interaction
When liquidity clusters around a price level, the resulting liquidity shelf can influence how price behaves when it approaches that area.
Price interaction with these shelves is state-dependent:
Research on order book dynamics supports this mechanical view of price movement.
For example:
Jean-Philippe Bouchaud, J. Doyne Farmer, and Fabrizio Lillo (2009) demonstrate that price impact emerges from the interaction between order flow and finite liquidity
From this perspective, price does not move simply because a level is crossed.
Price moves because available liquidity at that level has been consumed.
🔸Latent Liquidity and Stop Clustering
In addition to visible liquidity from limit orders, markets also contain latent liquidity.
This is where ”Stop-Loss Clustering (Breakouts)” becomes important - we’re almost done!
Latent liquidity consists of conditional orders such as stop-losses that are not visible in the order book until triggered.
Although these orders aren’t public information, empirical studies show that stop orders tend to cluster near widely referenced price levels.
Research by Carol Osler (2001, 2002) using institutional FX order data finds that stop-loss orders frequently accumulate just beyond salient price levels such as prior highs and lows.
When these stops trigger, they convert into aggressive market orders and can generate bursts of directional order flow that may accelerate price movement.
🔸Stop-Loss Cascades
Stop losses add another layer of latent order flow that isn’t visible in the order book until it triggers.
If enough of them sit around the same price area.. Think “hidden pressure” waiting to activate. Nothing happens while price trades nearby, but once that level is traded at, those stops convert into market orders and immediately begin consuming available liquidity.
This matters because stop placement is unlikely to be random in most instances. Traders frequently anchor stops to widely observed prices such as prior highs, prior lows, or other prominent structure points, or use volatility methods such as ATR, etc.
So when price approaches one of these areas, two things can happen.
If the resting liquidity there is large enough, the incoming orders can be absorbed and price may stall or reject.
But if that liquidity gets consumed, the stops sitting just beyond the level begin triggering. Those triggered stops add additional market orders, which consume more liquidity and can push price further into the next layer of stops.
This creates a cascading effect:
When this chain reaction starts, price can transition very quickly from a slow battle near the level to rapid expansion through it.
This is one of the mechanical reasons why some reference-point breaks barely move, while others accelerate rapidly.
🔹How It Works
Now that we understand the why - let’s discuss how the indicator works.
🔸Absorbtion Extremes

The image above shows the absorption extremes model.
In this model, the indicator treats recent & relevant swing points as plausible stop clustering candidates.
You can find similar swing point identification mechanics in other indicators.
However, this model assigns subsequent volume to the swing level after its formation.
There are limitations and assumptions - let’s go over them.

The images above explain how the indicator determines the intensity of a possible stop-cluster around a swing level.
There are limitations and assumptions
1: The indicator assigns all “directional volume” to a swing level after it’s formed and while it remains the closest active swing point to the current price.
“Buy volume” is assigned to the closest active swing low.
“Sell volume” is assigned to the closest active swing high.
I say “buy volume” and “sell volume” because there’s assumptions on what constitutes the relevant classification.
The indicators follow the traditional two-region tick model for classifying buy volume and sell volume.
Higher close = “buy volume” proxy
Lower close = “sell volume” proxy
Depending on the granularity you select (the indicator is capable of using tick data), this model can be more/less accurate.
However, even with tick-level data and bid/ask quotes, trade direction must still be inferred using classification rules. Because some trades occur inside the spread or involve hidden liquidity, perfect classification is not possible without exchange aggressor flags.
For assumptions..
The model assigns ALL classified volume to the swing level.
In reality, traders use a wide range of risk management methods, and not every position will place a stop loss directly at the most recent swing point. ATR-based stops, percentage-based stops, and other volatility-based methods are also common.
Because the true distribution of stop placement is unobservable, the model assumes that positions entered are structurally invalidated at the closest swing level based on their classified direction.
As a result, the values displayed by the indicator should be interpreted as relative proxies for potential stop concentration, rather than precise estimates of actual stop-loss size.
The displayed magnitudes are intentionally exaggerated and comparative, designed to highlight where stop pressure may accumulate relative to other levels.


The images above show how to interpret the indicator when using this model.
The image above shows the triggered stop-cluster graph.
Each point corresponds to a triggered stop-cluster - assuming it exists.
The greater the size attached to that cluster, the further distant the data point is placed.
Far away from zero line = large size.
Close to zero line = low size.
Radiating/glowing points indicate a potentially large cluster trigger.
🔸 Volatility-At-Entry Model (Time Scaled)
The Volatility-At-Entry model uses ATR scaled by various timeframes to predict plausible stop loss placements.
For this model, the indicator uses the same tick classification model to assign volume directionally.
Volume is then dispersed across six common timeframes (1m, 5m, 15m, 30m, 1h, 4h) and 3 common ATR multiples for risk management (1ATR, 1.5ATR, 2ATR).
This model assumes traders are entering positions across various timeframes and are scaling risk congruent with those timeframes.
For instance,
A trader using the 1-minute chart for opportunity is more likely to use a stop loss closer to entry than a trader using the 4-hour chart for opportunity.
If this assumption is reasonable to you - great, we can move forward!

The image above visualizes the model.
Purple-shaded regions indicate a price area with less opportunity for stop loss clustering. Either transaction intensity around eligible price areas was low, or position accumulation wasn’t given sufficient time.
Pink-shaded regions indicate a price area with greater opportunity for stop loss clustering. Volume was significant around these regions or price has traded within proximity for extended periods.

This model naturally shows more future opportunity than historical outcomes. You can select to show historical outcomes in the settings, this image shows examples of such outcomes.

The image above shows the triggered stop loss graph in effect for this model. Stop clustered are distributed across more price areas with this model - from low intensity to high intensity. Therefore, a cluster is almost always “triggering” to some degree.
A classification model for what’s typical and what’s unusual is used for the graph in this case. Radiating points always indicate large stop clusters triggered. Anything within the green/pink line indicates usual size.
Typical Move
The image above explains the nearest cluster information table.
The size and location of the nearest buy-stop cluster and sell-stop cluster are recorded.
Additionally, the indicator identifies whether clusters of similar size were triggered in the past, and how price behaved following those events.
Since all models here are highly assumptive, and similar sized clusters might only have one or two relative neighbors, treat these measurements as a description of history rather than a prediction.
The model takes the logarithm of the current stop-volume (buy or sell) to normalize its scale and compare it with a historical dataset of previously observed stop-volume sizes that have also been log-scaled.
It then identifies historical observations whose sizes are most similar to the current value, either by selecting all observations within a tolerance range around that value (where the range is based on the typical spacing between historical observations), or by selecting the single closest match.
Finally, the model retrieves the historical price moves associated with those matched observations, producing a sample of “typical moves” that occurred when stop-volume magnitude was similar to the current situation.
Ratio Meter

The stop-cluster ratio meter shows the current sum of active and triggered all buy-side clusters and sell-side clusters.
This meter is useful for quick scanning across assets to see if active or recently triggered stop clusters are lopsided.
Additional Features
The single most important setting outside model selection is the lower timeframe used to retrieve volume from.
This setting is set to 1-minute data by default because it works with paid and free plans. If you want better granularity, I strongly suggest changing this setting to either 1-second or 1-tick. This will sacrifice the number of identifiable cluster locations, because better granularity data has less programmatically retrievable values.
🔹Closing Remarks
Stop-loss clustering is an appealing concept because it offers a plausible explanation for why some breakouts accelerate so quickly while others stall. When a large number of conditional orders sit near the same price, a breakout through that area can trigger a cascade of market orders that rapidly consume liquidity and push price toward the next available zone.
However, it’s important to remember that the models used in this indicator are approximations, not direct measurements. True stop-loss locations and sizes are not publicly observable, and many traders use different risk management techniques that cannot be perfectly inferred from chart data alone. The goal of this indicator is therefore not to identify exact stop locations, but to highlight price areas where stop pressure may plausibly accumulate relative to surrounding levels.
Like any model based on behavioral assumptions and historical observations, results should be interpreted probabilistically. Large clusters do not guarantee breakouts, and small clusters do not guarantee quiet price behavior. Instead, the indicator is best used as a tool for context and situational awareness.
References
General Microstructure and Price Formation
Madhavan, A. (2000). Market microstructure: A survey. Journal of Financial Markets, 3(3), 205–258.
O'Hara, M. (1995). Market Microstructure Theory. Blackwell.
Biais, B., Glosten, L., & Spatt, C. (2005). Market microstructure: A survey of microfoundations, empirical results, and policy implications. Journal of Financial Markets, 8(2), 217–264.
Limit Order Books and Liquidity as Resting Orders
Gould, M. D., Porter, M. A., Williams, S., McDonald, M., Fenn, D. J., & Howison, S. D. (2013). Limit order books. Quantitative Finance, 13(11), 1709–1742.
Rosu, I. (2009). A dynamic model of the limit order book. Review of Financial Studies, 22(11), 4601–4641.
Biais, B., Hillion, P., & Spatt, C. (1995). An empirical analysis of the limit order book and the order flow in the Paris Bourse. Journal of Finance, 50(5), 1655–1689.
Liquidity Clustering and Depth Concentration
Kavajecz, K. A., & Odders-White, E. R. (2004). Technical analysis and liquidity provision. Review of Financial Studies, 17(4), 1043–1071.
Bourghelle, D., & Cellier, A. (2007). Limit order clustering and price barriers on financial markets. Working paper / SSRN.
Order Flow and Price Impact
Bouchaud, J.-P., Farmer, J. D., & Lillo, F. (2009). How markets slowly digest changes in supply and demand. In Handbook of Financial Markets: Dynamics and Evolution.
Stop Orders and Price Cascades
Osler, C. L. (2003). Currency orders and exchange-rate dynamics: Explaining the success of technical analysis. Journal of Finance, 58(5), 1791–1819.
Osler, C. L. (2005). Stop-loss orders and price cascades in currency markets. Journal of International Money and Finance, 24(2), 219–241.
Liquidity Provision and Execution
Ho, T., & Stoll, H. (1981). Optimal dealer pricing under transactions and return uncertainty. Journal of Financial Economics, 9(1), 47–73.
Almgren, R., & Chriss, N. (2000). Optimal execution of portfolio transactions. Journal of Risk, 3(2), 5–39.
Menkveld, A. J. (2013). High frequency trading and the new market makers. Journal of Financial Markets, 16(4), 712–740.
Behavioral Anchoring and Attention
Kahneman, D., & Tversky, A. (1974). Judgment under uncertainty: Heuristics and biases. Science, 185(4157), 1124–1131.
Barber, B. M., & Odean, T. (2008). All that glitters: The effect of attention and news on the buying behavior of individual and institutional investors. Review of Financial Studies, 21(2), 785–818.
George, T. J., & Hwang, C. Y. (2004). The 52-week high and momentum investing. Journal of Finance, 59(5), 2145–2176.
Mizrach, B., & Weerts, S. (2007). Highs and lows: A behavioral and technical analysis. SSRN working paper.
🔹Introduction
This indicator "Stop-Loss Clustering (Breakouts)" attempts to model trader stop-loss placement logic and identify price areas where a large amount of stop losses might cluster.
The idea is, if stop losses are indeed highly concentrated in a specific area, price extending through that area may produce high-velocity breakout conditions via forced order flow.
I'll cover this topic more thoroughly throughout the description. For now, just know that stop loss location & size data is not publicly available. Any model of their concentration locations is highly assumptive.
However, there's some reasonable academic research we can reference to make worthwhile estimates.
Academic references supporting the concepts discussed are listed at the end of this description. To maintain readability, I won't cite individual statements inline.
🔹The Premise
🔸Liquidity, Behavior, and Stop Cascades
Markets operate through a continuous limit order book, where two fundamental order types interact:
- Limit orders, which provide liquidity by resting in the book
- Market orders, which consume liquidity by exhausting those resting orders
This mechanical interaction drives price movement - incoming order flow consuming available liquidity.
This begs the question.. Does liquidity distribute evenly across the LOB?
If it did: If liquidity were evenly distributed, price impact could be modeled as a relatively smooth function of incoming order flow.
But it doesn’t: Liquidity is unevenly distributed. Academic research supports this claim and, regardless, this is an intuitive conclusion most traders arrive at.
Liquidity forms localized concentrations and gaps.
Liquidity concentrations are commonly referenced as:liquidity shelves, liquidity clusters, liquidity zones.
Liquidity gaps are commonly referenced as: liquidity vacuums, thin book zones.
As a result, identical order flow can produce very different price movements depending on the state of the order book.
Let’s consider an example..
Assume price is trading at $99.
The price levels $100, $101, $102 have resting sell limit order concentrations of 100.
This is where you come in.
You execute a market order buy for 300 size.
Your order first exhausts all sell-side resting order concentrations at the $100 level.
You still have 200 size that needs to be filled, and the ask price has moved from $100 to $101.
Your order will now sequentially exhaust available liquidity at the $101 level, the ask price will increase to $102, and your final 100 size will exhaust the $102 level.
To keep the example simple, we’ll say that your order moved price from $99 to $102, and now the ask price is $103.
But, you still want to accumulate.
The nearest sell-side levels in the LOB are $103, $104, $105.
The $103 level has a sell limit order concentration of 500.
$104 and $105 both have concentrations of 50.
You execute your same market order buy for 300 size.
This time, price doesn’t move.. At all..
Instead, you consumed 300 of the 500 size at $103 with your order, and the level remains a barrier.
Your order was absorbed by available liquidity.
This example demonstrates how price movement depends on available liquidity, not simply the size of incoming orders.
In the first scenario, liquidity was thin and the order walked through multiple price levels, causing price to move quickly.
In the second scenario, a large concentration of resting liquidity absorbed the same order, preventing price from advancing.
🔸Liquidity Does Not Distribute Evenly
Alright, we understand that liquidity doesn’t distribute evenly. And we understand that high concentrations of liquidity can act as price barriers (liquidity shelves) while sparse liquidity can permit rapid price movement - we saw this in our example above.
There’s an important question we should ask next before we move on..
If liquidity distributes unevenly, then where does it tend to cluster? And where does it tend to thin?
Of course, knowing these tendencies provides multi-purpose advantages.
If price approaches a liquidity vacuum - a local block of the order book with thin resting liquidity - rapid price movement can occur without requiring unusually strong aggressive order flow.
If price approaches a liquidity shelf - a local block of the order book with thick resting liquidity - price can stall or contract even if the same level of aggressive order flow that previously moved price continues.
With this in mind, order flow intensity alone does not determine price movement. The distribution of liquidity across surrounding price levels plays a similarly important role.
So, is there any evidence of where liquidity tends to concentrate?
🔸Empirical Observations
Empirical research on limit order books shows that liquidity does not distribute smoothly across the LOB. Instead, depth tends to concentrate at specific price levels, producing irregular profiles with localized peaks in resting liquidity.
These concentrations arise because order placement is not random. Traders frequently anchor decisions to widely observed reference prices such as:
• prior highs
• prior lows
• round numbers
• widely referenced price extremes
Because many traders monitor the same price history, order placement decisions often reference similar price levels.
This concept is simpler than it sounds.
Let’s use market structure traders for example.
Market structure traders frequently reference prior swing highs and swing lows when making decisions about entries, exits, and risk.
A trader entering a long position may place their stop-loss below a recent swing low, reasoning that if price breaks that level, the trade idea is invalidated.
A trader entering a short position may place their stop-loss above a recent swing high for the same reason.
Timeframe price aggregation may differ; however, we’re all looking at roughly the same recent highs and lows when evaluating a chart (structure).
When many traders collectively reference the same prices, orders may accumulate near those levels. This produces localized depth concentrations, which traders refer to as liquidity shelves.
Liquidity shelves act as temporary barriers where the book contains disproportionately large resting liquidity compared to surrounding prices.
🔸Research documenting liquidity clustering includes:
Bourghelle & Cellier (2007), who find that limit orders cluster at prominent price levels (especially round numbers), creating localized depth concentrations that can act as price barriers.
Kavajecz & Odders-White (2004), who demonstrate that prices identified as support or resistance coincide with higher resting limit order depth
These findings suggest that many commonly observed price levels may correspond to real concentrations of liquidity rather than being purely visual artifacts on a chart.
Kavajecz & Odders-White (2004) is an important observation for support/resistance traders!
Kavajecz & Odders-White (2004) show that levels traders commonly call support and resistance often align with areas where more limit orders are resting in the order book.
This suggests a plausible mechanical pathway through which support and resistance levels can emerge!
🔸Liquidity Shelves and Price Interaction
When liquidity clusters around a price level, the resulting liquidity shelf can influence how price behaves when it approaches that area.
Price interaction with these shelves is state-dependent:
- If incoming order flow is absorbed, price may stall or reverse
- If resting liquidity is consumed, price may transition rapidly to the next liquidity zone
- Once a shelf is depleted, follow-through can accelerate due to thinner liquidity beyond the level
Research on order book dynamics supports this mechanical view of price movement.
For example:
Jean-Philippe Bouchaud, J. Doyne Farmer, and Fabrizio Lillo (2009) demonstrate that price impact emerges from the interaction between order flow and finite liquidity
From this perspective, price does not move simply because a level is crossed.
Price moves because available liquidity at that level has been consumed.
🔸Latent Liquidity and Stop Clustering
In addition to visible liquidity from limit orders, markets also contain latent liquidity.
This is where ”Stop-Loss Clustering (Breakouts)” becomes important - we’re almost done!
Latent liquidity consists of conditional orders such as stop-losses that are not visible in the order book until triggered.
Although these orders aren’t public information, empirical studies show that stop orders tend to cluster near widely referenced price levels.
Research by Carol Osler (2001, 2002) using institutional FX order data finds that stop-loss orders frequently accumulate just beyond salient price levels such as prior highs and lows.
When these stops trigger, they convert into aggressive market orders and can generate bursts of directional order flow that may accelerate price movement.
🔸Stop-Loss Cascades
Stop losses add another layer of latent order flow that isn’t visible in the order book until it triggers.
If enough of them sit around the same price area.. Think “hidden pressure” waiting to activate. Nothing happens while price trades nearby, but once that level is traded at, those stops convert into market orders and immediately begin consuming available liquidity.
This matters because stop placement is unlikely to be random in most instances. Traders frequently anchor stops to widely observed prices such as prior highs, prior lows, or other prominent structure points, or use volatility methods such as ATR, etc.
So when price approaches one of these areas, two things can happen.
If the resting liquidity there is large enough, the incoming orders can be absorbed and price may stall or reject.
But if that liquidity gets consumed, the stops sitting just beyond the level begin triggering. Those triggered stops add additional market orders, which consume more liquidity and can push price further into the next layer of stops.
This creates a cascading effect:
- price reaches a stop cluster
- stops trigger and convert into market orders
- liquidity gets consumed faster
- price moves further, triggering more stops
When this chain reaction starts, price can transition very quickly from a slow battle near the level to rapid expansion through it.
This is one of the mechanical reasons why some reference-point breaks barely move, while others accelerate rapidly.
🔹How It Works
Now that we understand the why - let’s discuss how the indicator works.
🔸Absorbtion Extremes
The image above shows the absorption extremes model.
In this model, the indicator treats recent & relevant swing points as plausible stop clustering candidates.
You can find similar swing point identification mechanics in other indicators.
However, this model assigns subsequent volume to the swing level after its formation.
There are limitations and assumptions - let’s go over them.
The images above explain how the indicator determines the intensity of a possible stop-cluster around a swing level.
There are limitations and assumptions
1: The indicator assigns all “directional volume” to a swing level after it’s formed and while it remains the closest active swing point to the current price.
“Buy volume” is assigned to the closest active swing low.
“Sell volume” is assigned to the closest active swing high.
I say “buy volume” and “sell volume” because there’s assumptions on what constitutes the relevant classification.
The indicators follow the traditional two-region tick model for classifying buy volume and sell volume.
Higher close = “buy volume” proxy
Lower close = “sell volume” proxy
Depending on the granularity you select (the indicator is capable of using tick data), this model can be more/less accurate.
However, even with tick-level data and bid/ask quotes, trade direction must still be inferred using classification rules. Because some trades occur inside the spread or involve hidden liquidity, perfect classification is not possible without exchange aggressor flags.
For assumptions..
The model assigns ALL classified volume to the swing level.
In reality, traders use a wide range of risk management methods, and not every position will place a stop loss directly at the most recent swing point. ATR-based stops, percentage-based stops, and other volatility-based methods are also common.
Because the true distribution of stop placement is unobservable, the model assumes that positions entered are structurally invalidated at the closest swing level based on their classified direction.
As a result, the values displayed by the indicator should be interpreted as relative proxies for potential stop concentration, rather than precise estimates of actual stop-loss size.
The displayed magnitudes are intentionally exaggerated and comparative, designed to highlight where stop pressure may accumulate relative to other levels.
The images above show how to interpret the indicator when using this model.
The image above shows the triggered stop-cluster graph.
Each point corresponds to a triggered stop-cluster - assuming it exists.
The greater the size attached to that cluster, the further distant the data point is placed.
Far away from zero line = large size.
Close to zero line = low size.
Radiating/glowing points indicate a potentially large cluster trigger.
🔸 Volatility-At-Entry Model (Time Scaled)
The Volatility-At-Entry model uses ATR scaled by various timeframes to predict plausible stop loss placements.
For this model, the indicator uses the same tick classification model to assign volume directionally.
Volume is then dispersed across six common timeframes (1m, 5m, 15m, 30m, 1h, 4h) and 3 common ATR multiples for risk management (1ATR, 1.5ATR, 2ATR).
This model assumes traders are entering positions across various timeframes and are scaling risk congruent with those timeframes.
For instance,
A trader using the 1-minute chart for opportunity is more likely to use a stop loss closer to entry than a trader using the 4-hour chart for opportunity.
If this assumption is reasonable to you - great, we can move forward!
The image above visualizes the model.
Purple-shaded regions indicate a price area with less opportunity for stop loss clustering. Either transaction intensity around eligible price areas was low, or position accumulation wasn’t given sufficient time.
Pink-shaded regions indicate a price area with greater opportunity for stop loss clustering. Volume was significant around these regions or price has traded within proximity for extended periods.
This model naturally shows more future opportunity than historical outcomes. You can select to show historical outcomes in the settings, this image shows examples of such outcomes.
The image above shows the triggered stop loss graph in effect for this model. Stop clustered are distributed across more price areas with this model - from low intensity to high intensity. Therefore, a cluster is almost always “triggering” to some degree.
A classification model for what’s typical and what’s unusual is used for the graph in this case. Radiating points always indicate large stop clusters triggered. Anything within the green/pink line indicates usual size.
Typical Move
The image above explains the nearest cluster information table.
The size and location of the nearest buy-stop cluster and sell-stop cluster are recorded.
Additionally, the indicator identifies whether clusters of similar size were triggered in the past, and how price behaved following those events.
Since all models here are highly assumptive, and similar sized clusters might only have one or two relative neighbors, treat these measurements as a description of history rather than a prediction.
The model takes the logarithm of the current stop-volume (buy or sell) to normalize its scale and compare it with a historical dataset of previously observed stop-volume sizes that have also been log-scaled.
It then identifies historical observations whose sizes are most similar to the current value, either by selecting all observations within a tolerance range around that value (where the range is based on the typical spacing between historical observations), or by selecting the single closest match.
Finally, the model retrieves the historical price moves associated with those matched observations, producing a sample of “typical moves” that occurred when stop-volume magnitude was similar to the current situation.
Ratio Meter
The stop-cluster ratio meter shows the current sum of active and triggered all buy-side clusters and sell-side clusters.
This meter is useful for quick scanning across assets to see if active or recently triggered stop clusters are lopsided.
Additional Features
The single most important setting outside model selection is the lower timeframe used to retrieve volume from.
This setting is set to 1-minute data by default because it works with paid and free plans. If you want better granularity, I strongly suggest changing this setting to either 1-second or 1-tick. This will sacrifice the number of identifiable cluster locations, because better granularity data has less programmatically retrievable values.
🔹Closing Remarks
Stop-loss clustering is an appealing concept because it offers a plausible explanation for why some breakouts accelerate so quickly while others stall. When a large number of conditional orders sit near the same price, a breakout through that area can trigger a cascade of market orders that rapidly consume liquidity and push price toward the next available zone.
However, it’s important to remember that the models used in this indicator are approximations, not direct measurements. True stop-loss locations and sizes are not publicly observable, and many traders use different risk management techniques that cannot be perfectly inferred from chart data alone. The goal of this indicator is therefore not to identify exact stop locations, but to highlight price areas where stop pressure may plausibly accumulate relative to surrounding levels.
Like any model based on behavioral assumptions and historical observations, results should be interpreted probabilistically. Large clusters do not guarantee breakouts, and small clusters do not guarantee quiet price behavior. Instead, the indicator is best used as a tool for context and situational awareness.
References
General Microstructure and Price Formation
Madhavan, A. (2000). Market microstructure: A survey. Journal of Financial Markets, 3(3), 205–258.
O'Hara, M. (1995). Market Microstructure Theory. Blackwell.
Biais, B., Glosten, L., & Spatt, C. (2005). Market microstructure: A survey of microfoundations, empirical results, and policy implications. Journal of Financial Markets, 8(2), 217–264.
Limit Order Books and Liquidity as Resting Orders
Gould, M. D., Porter, M. A., Williams, S., McDonald, M., Fenn, D. J., & Howison, S. D. (2013). Limit order books. Quantitative Finance, 13(11), 1709–1742.
Rosu, I. (2009). A dynamic model of the limit order book. Review of Financial Studies, 22(11), 4601–4641.
Biais, B., Hillion, P., & Spatt, C. (1995). An empirical analysis of the limit order book and the order flow in the Paris Bourse. Journal of Finance, 50(5), 1655–1689.
Liquidity Clustering and Depth Concentration
Kavajecz, K. A., & Odders-White, E. R. (2004). Technical analysis and liquidity provision. Review of Financial Studies, 17(4), 1043–1071.
Bourghelle, D., & Cellier, A. (2007). Limit order clustering and price barriers on financial markets. Working paper / SSRN.
Order Flow and Price Impact
Bouchaud, J.-P., Farmer, J. D., & Lillo, F. (2009). How markets slowly digest changes in supply and demand. In Handbook of Financial Markets: Dynamics and Evolution.
Stop Orders and Price Cascades
Osler, C. L. (2003). Currency orders and exchange-rate dynamics: Explaining the success of technical analysis. Journal of Finance, 58(5), 1791–1819.
Osler, C. L. (2005). Stop-loss orders and price cascades in currency markets. Journal of International Money and Finance, 24(2), 219–241.
Liquidity Provision and Execution
Ho, T., & Stoll, H. (1981). Optimal dealer pricing under transactions and return uncertainty. Journal of Financial Economics, 9(1), 47–73.
Almgren, R., & Chriss, N. (2000). Optimal execution of portfolio transactions. Journal of Risk, 3(2), 5–39.
Menkveld, A. J. (2013). High frequency trading and the new market makers. Journal of Financial Markets, 16(4), 712–740.
Behavioral Anchoring and Attention
Kahneman, D., & Tversky, A. (1974). Judgment under uncertainty: Heuristics and biases. Science, 185(4157), 1124–1131.
Barber, B. M., & Odean, T. (2008). All that glitters: The effect of attention and news on the buying behavior of individual and institutional investors. Review of Financial Studies, 21(2), 785–818.
George, T. J., & Hwang, C. Y. (2004). The 52-week high and momentum investing. Journal of Finance, 59(5), 2145–2176.
Mizrach, B., & Weerts, S. (2007). Highs and lows: A behavioral and technical analysis. SSRN working paper.
Phát hành các Ghi chú
version -- 1.001- Removed unused variable from code
- Updated main chart image
Phát hành các Ghi chú
Added a fix for error on out of bounds read operation - thank you for pointing this out guys!Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
•Access to Next-Gen Optimization Tools: tradingiq.io
•Discord Server: discord.gg/aKWPuM4HPy
•Discord Server: discord.gg/aKWPuM4HPy
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
•Access to Next-Gen Optimization Tools: tradingiq.io
•Discord Server: discord.gg/aKWPuM4HPy
•Discord Server: discord.gg/aKWPuM4HPy
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
