Article contents
- Evidence and scope
- Illustration
- Process
- Three reference types with different information
- Session identifiers and eligibility timestamps
- Same-time volume and opening-auction treatment
- Synthetic opening-range examples
- Separate the lifetime of the level and the trade
- Separate the level effect from the time-of-day effect
- Common pitfalls
- Practical checklist
- Frequently asked questions
- Research sources
Evidence and scope
The source indicator describes configurable session sweeps; platform and exchange documentation establish session mechanics. No profitability claim is verified for the proposed detector.
Practical workflow
- Define the sessionSelect venue, calendar and timezone.
- Complete the reference windowPublish prior-session or opening-range extremes only when known.
- Detect a later sweepUse fixed buffers and eligible level versions.
- Confirm and submitRespect close receipt and the chosen order model.
- Evaluate by session typeInclude no-signal days, gaps and calendar edge cases.
Three reference types with different information
PDH/PDL are the high and low of the previous completed trading day. PSH/PSL refer to a selected completed session, while ORH/ORL describe the first N minutes of the current session. Their prices can coincide without becoming independent evidence. Store one underlying reference with the relevant labels when appropriate.
LuxAlgo’s Session Sweeps allows session selection [1]. An independent implementation needs an exchange timezone and calendar [2][3], rather than one fixed local clock time throughout the year. London, New York and the computer running the strategy may not change clocks on the same date.
Previous-day levels describe an older range; the opening range describes the start of the new day. A large gap may place price beyond the entire previous range at the open. Returning to PDH is not automatically a sweep: identify the starting side of the level and whether the intended trigger is rejection, reclaim or breakout retest.
Session identifiers and eligibility timestamps
A proposed session_id contains venue, symbol, calendar_date and session_template_version. A US-equity baseline can use the core session and store premarket separately. Flag shortened sessions instead of inventing missing bars to produce a uniform 24-hour day. Overnight futures can have a trading date different from the local calendar date.
For an opening range from 09:30 to 09:45, five-minute bars starting at 09:30, 09:35 and 09:40 belong to the range. Publish its final levels only after 09:45. The incomplete 09:40 bar does not reveal the final OR low. Half-open intervals [start,end) prevent an event exactly at the boundary from entering both windows.
After support S is published, a proposed downside sweep requires the previous close above S, low<S−b and close>S+e. Use b=max(2 ticks,0.10ATR) and e=max(2 ticks,0.15ATR), with ATR from the bar before the trigger. A multi-bar K=3 reclaim is a separate version. N, K and all buffers are research choices, not established profitable settings.
Record both window_end and publication receipt. If the feed delivers a corrected final range late, it cannot retroactively authorize an earlier entry. Decide whether revisions affect future candidates only or invalidate the affected research interval, and preserve the original decision log.
on_trade_received(trade):
window = configured_half_open_window(trade.event_time)
if window.start <= trade.event_time < window.end:
update_extrema_for_that_window_only(window,trade)
on_window_data_ready(window,received_at):
if not window_complete_under_declared_watermark_policy: return
if window.current_fingerprint == window.last_published_fingerprint: return
available_at = max(window.end,received_at) + processing_delay
publish_frozen_version(window.extrema,available_at=available_at)
window.last_published_fingerprint = window.current_fingerprint
for closed_bar in later_bars:
levels = versions_available_before(closed_bar.start)
detect_sweep(levels,closed_bar)
# Publish once per data version; boundary trades belong to the following window.
# Late corrections publish a future version and never backdate an order.
Same-time volume and opening-auction treatment
Compare trigger volume with the matching time slot in earlier sessions. Missing slots and shortened days require explicit exclusions. A feed that places auction volume in the first bar should not be compared directly with a history that removes those prints.
Sweep RVOL and location relative to the current VWAP are separate proposed features. Morning decisions cannot use end-of-day VWAP. Sweeping PDL while trading below VWAP may reflect one downward move, so measure each filter’s incremental value instead of simply counting confirmations.
Signals immediately before and after a scheduled announcement can have different fills. A calendar known beforehand can identify those windows. Calling a day bad-news after observing its price response introduces hindsight. Store the announced timestamp separately from the actual time the data or headline was received.
Synthetic opening-range examples
Suppose a chart is intended to have OR15 high=205 and low=200. At 09:43, however, price trades to 199.80 and recovers. You cannot trade a sweep of the supposed final low at 200 because the opening range is still forming. If 199.80 is a valid observation in that window, the final OR low must include it.
In a separate example, the opening range has already ended with low=200. A later 09:50 bar has low=199.60 and close=200.40. Assuming the tick-size floor does not dominate, prior ATR=1 gives b=0.10 and e=0.15, so the reclaim qualifies. A post-close fill at 200.45, stop at 199.50 and target at 202.35 has risk 0.95 and reward 1.90. The target is fixed at entry rather than selected from the eventual daily high.
A losing path reaches 199.45 and fills protection at 199.48, losing 0.97. A different bar closing at 199.70 and holding below ORL is a break/acceptance control, not a reversal entry. A new calendar day must not replace an existing trade’s stop with the newly calculated PDL.
Separate the lifetime of the level and the trade
A reference may expire at the session close while an already open trade follows its own exit policy. For waiting candidates, a proposed baseline takes only the first eligible sweep per level_id per session. Test later touches separately to determine whether outcomes are concentrated in the first approach.
If entry requires a break above the reclaim candle, the stop-entry order can exist only after that candle completes. A next-bar trigger followed by a stop is still a trade even if the final close looks unattractive. A bar sweeping both range boundaries needs intrabar records or an insufficient-sequencing flag.
Store UTC, the exchange timezone, original event time and local receive time. At a futures roll, do not compare an unadjusted new-contract price with a previous-day level from the old contract. The continuous research chart and the traded contract need a documented mapping.
A practical test should also include a session with delayed opening or a halt across the range boundary. Decide whether the opening range means clock time or elapsed tradable minutes. Those definitions produce different levels and must not be switched after discovering which one gave a better trade.
Separate the level effect from the time-of-day effect
Compare PDH/PDL sweeps with rolling references at similar distances from price, or synthetic levels with comparable density. Match by minute within the session, gap size and volatility. Comparing opening sweeps with every quiet minute of the day can mostly measure the opening period itself.
Report results by reference type, session template, daylight-saving regime and gap category. Test known holidays and shortened sessions against the calendar engine. Net expectancy and no-fill rates belong alongside capital-level results that retain sessions with no signal.
Boundary tests should include trades exactly at window_start and window_end, duplicate timestamps, missing bars, late corrections and the first session after a timezone transition. Preserve a version of the calendar used for each run. A small number of attractive examples does not establish that the strategy offers enough opportunities to justify its monitoring and execution costs.
Common pitfalls
Using the unfinished day high or low
The final extreme contains information unavailable during the session.
Fixing one local opening time year-round
Clock changes and calendar differences can shift the intended window.
Counting coincident references repeatedly
ORL, session low and PDL at the same price may describe one event.
Checklist before using this method
Check each item after verifying it on your data. Progress is saved in this browser; it does not certify a profitable strategy.
Frequently asked questions
Can a sweep occur inside the opening range itself?
Price can cross a provisional boundary, but that is a different detector. It cannot use the final ORH/ORL before the opening window has completed.
Must the first sweep be the best?
No. First-touch is a proposed policy to make episodes independent. Later touches should be retained and tested as separate variants.
Research sources
Each source supports the definition or evidence described beside it. The pseudocode, synthetic examples and proposed parameters require separate validation.
- Session SweepsLuxAlgo on TradingView. Read the original session-sweep description; profitability was not verified. Checked: .
- SessionsTradingView. Read session and timezone mechanics, not alpha research. Checked: .
- Holidays and Trading HoursNYSE. Opened the official calendar and trading-hours reference. Checked: .
Related methods
Risk note
This content supports education and research design, not financial advice. Backtest is historical simulation, does not guarantee future performance and does not place real trades. Methods in this library are not automatically features available in the app. See methodology and learning center.
Validate rules before risking real capital
Check app support, data and individual simulated trades; advanced detectors may require a separate implementation.
Download Backtest on the App Store