Detect ranging market using price action

 
Anyone here have any experience build EA/Indicator that detect ranging market using price action? If yes what would be the most efficient way to detect ranging market using price action?
 
Eka Rudianto:
Anyone here have any experience build EA/Indicator that detect ranging market using price action? If yes what would be the most efficient way to detect ranging market using price action?
find a candle and detect x number of candles after that to check if they are within a price range up and down and that way you can code indicator to achieve what you want.
 

I had posted a custom indicator on the codebase before which is for detecting ranging market by measuring volatility on consecutive bars

 

This is "Elders Safe Zone" made by Mladen before, which is also clearly a good one to detect both the trend and the ranging area

There are many more ways to detect a ranging market area, for example

- Measuring the slope of a moving average. If the slope magnitude isn't passing a defined threshold, the market is ranging

- Connecting a line to fractal points. If the price stays between the high and low fractal lines, the market is ranging

Files:
 
Conor Mcnamara #:

This is "Elders Safe Zone" made by Mladen before, which is also clearly a good one to detect both the trend and the ranging area

There are many more ways to detect a ranging market area, for example

- Measuring the slope of a moving average. If the slope magnitude isn't passing a defined threshold, the market is ranging

- Connecting a line to fractal points. If the price stays between the high and low fractal lines, the market is ranging

Hi thanks for the reply! seems like both of the scripts you attached relied on indicators. Was wondering if you have some approach purely based on price action only?
 
Eka Rudianto #:
Hi thanks for the reply! seems like both of the scripts you attached relied on indicators. Was wondering if you have some approach purely based on price action only?

this is a range channel formed between two trendlines which is based on price action and time, the input is by default 1 hour, which means that it is painting the H1 range regardless of what lower timeframe you're on

It repaints because price action based indicators always repaint. ATR based indicators don't tend to repaint like price action based indicators, as volatility (calculated over a period) changes gradually and doesn't change so fast and abruptly.

Files:
 
Eka Rudianto:
Anyone here have any experience build EA/Indicator that detect ranging market using price action? If yes what would be the most efficient way to detect ranging market using price action?
 The high and low of number of bars back