Why does Breakout Rider print entries in the wrong position on the Renko Box?
Get Quick Answers
The short answer is that it works as intended. The long answer comes down to how Pine Script and TradingView’s broker emulator handle Renko bars. (Guided Demo at the bottom of the page)
Renko bricks are built on synthetic open, high, low, and close values. Pine Script uses the open price of the bar for execution logic, which means entries are not simply placed at the top of a bullish brick or the bottom of a bearish brick for visual neatness. Instead, they are plotted according to where the conditions for entry were met in relation to the brick’s calculated opening.
Some traders using Renko strategies circumvent this issue visually by utilising TradingView’s “On Bar Close” setting.
This forces the entry to occur as soon as all the conditions are met within a brick and then executes at that brick’s close, rather than waiting for the next brick. Because of this, the plotted entry often appears in the “correct” visual location. However, this does not truly fix the underlying Pine Script behaviour. It simply changes the strategy logic so that it acts on the current brick instead of the following one. Even with this setting, you will often see exit markers printed in visually “incorrect” spots, because the core open/close mechanics of Renko bricks remain the same.
With the Breakout Rider Strategy, “On Bar Close” does not work in the same way because of our stop entry and limit order conditions.
When all the long conditions are met, a green triangle is plotted, signalling that the next brick should be a long entry. If that next brick is in the opposite direction, for example, a bearish red brick, the strategy cancels the trade and plots a large red X instead. This prevents entering trades when the price has already moved against the bias, helping to avoid being chopped up in consolidation.
This feature is highly valuable for live forward testing because it saves real money by filtering out low-quality trades.
However, it overrides the “On Bar Close” behaviour, meaning that setting will not adjust the printed entry position for the Breakout Rider. While removing this filter would allow “On Bar Close” to work visually, the trade-off is losing a significant protective mechanism that has proven highly effective in forward testing. In the guided demo below, you can see examples of how this logic works.
(WE RECOMMEND WATCHING THIS IN FULL SCREEN - TOP RIGHT-HAND CORNER OF THE GUIDED DEMO)
Last updated