Separate a breakout from a confirmed entry

A single close above resistance can reverse on the next bar. A two-close confirmation rule delays entry until price remains above a fixed reference level for two completed bars. This can filter some brief excursions but sacrifices entry speed and does not guarantee better performance.

Build a frozen reference

For an intraday strategy, record the highest high of the first 30 minutes of the configured trading session, then freeze it until the next session. Use a chart interval aligned with the opening range. Do not evaluate confirmation until two eligible bars have closed after the range ends. A close at or below the level resets the consecutive count.

Example: the frozen level is 100. Closes of 101 and 99 fail confirmation; later closes of 102 and 103 qualify. The first qualifying signal occurs at 103, not 102. A subsequent close of 104 is not another fresh signal.

Two-Close Confirmation for Opening Range Breakout Strategies

Illustrative closes: bar 3 breaks above 100 but bar 4 resets the sequence; bars 6 and 7 confirm the second attempt.

ACSIL implementation

In an AutoLoop study, use GetBarHasClosedStatus to avoid treating an unfinished bar as confirmation. The following signal fragment assumes the reference has already been frozen and the eligible-bar window has been checked. Configure Subgraph 0 as a visible marker and clear its value before recalculating the signal.

// ACSIL fragment: AutoLoop enabled, fixed range supplied
if (sc.GetBarHasClosedStatus() != BHCS_BAR_HAS_CLOSED)
    return;
if (sc.Index < 1)
    return;
const float level = 100.0f; // illustrative frozen range
bool confirmed = sc.Close[sc.Index] > level
    && sc.Close[sc.Index - 1] > level;
bool firstConfirmation = sc.Index >= 2
    && sc.Close[sc.Index - 2] <= level;
if (confirmed && firstConfirmation)
{
    // Signal only: connect to validated order management.
    sc.Subgraph[0][sc.Index] = sc.Low[sc.Index];
}

For production, replace the constant with the session-specific opening range, ensure all three referenced bars belong to the eligible window (or explicitly handle the first two eligible bars), and reset state at session boundaries. The first two eligible bars can be handled with a consecutive-close counter initialized to zero. Keep a last-processed-bar identifier to prevent duplicate live submissions. Use sc.GetTradePosition to check position state, then submit a validated s_SCNewOrder through sc.BuyEntry. Check working orders and return values, use attached protective orders, and distinguish a signal from an actual execution. Do not submit live orders during historical recalculation. A simple exit design is a fixed tick stop and session-end flattening; configure both explicitly before enabling trading.

Testing and risk

Compare one-close and two-close rules with the same opening range, exit rules, commissions and slippage. Examine delayed fills, gaps, session boundaries and repeated signals in replay and simulation. Use out-of-sample periods. This fragment is illustrative and has not been compiled or backtested here. Futures trading involves substantial risk; stop orders may execute at worse prices than expected.

For session-aware automation and execution controls, see Custom Sierra Chart strategy Development Services.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.