ForexBestRobots.comCompare EAs →
EN

Mean reversion · Envelopes + RSI

Envelopes and RSI Forex Strategy: Confirmed Re-entry and a Frozen Mean Target on Real USD/JPY Data

Test a fixed USD/JPY H1 Envelopes re-entry: 303 daily candidates, 32 baseline trades and only 2 RSI-retained trades, with real charts, a frozen mean target and explicit costs.

Real USD/JPY H1, candidate 3 on 16 January 2024. E 06:00, C/I 07:00 UTC. Both models admit the short at the observed 146.07 opening quote. Stop and rounded mean target are known; later candles and exit are hidden.
Real USD/JPY H1, candidate 3 on 16 January 2024. E 06:00, C/I 07:00 UTC. Both models admit the short at the observed 146.07 opening quote. Stop and rounded mean target are known; later candles and exit are hidden.

A close beyond a percentage envelope is an excursion, not an instruction to fade the trend immediately. This USD/JPY H1 study waits for the next completed candle to return inside frozen bands, then checks the remaining room to a fixed mean target. The 2024–2025 replay admits 32 baseline positions; the RSI rule retains only 2, both in 2024, and none in 2025. At a 2-pip total cost allowance, the paired totals are −0.16 R and −2.36 R. The filter is highly selective, and this sample does not establish a trading edge.

1. Define the return before considering an order

The model buys after a lower-band excursion returns upward, and sells after an upper-band excursion returns downward. It waits for a completed confirmation rather than treating an outside close or an intrabar touch as an entry. A stop beyond the two observed candles and a target derived from the excursion mean make the price rules explicit.

Base and RSI share those price rules and the same first-excursion calendar. RSI adds a specified momentum recovery condition; it does not move the entry, protection or exit of a retained position. A less crowded calendar is not evidence that the remaining positions are better.

2. State the percentage, smoothing and UTC clock

The middle M is the arithmetic mean of the last 20 recorded H1 closes, including the completed selected group. Upper and lower bands are M × 1.002 and M × 0.998: 0.20% means 0.002, not 20%, 0.20 pips or an ATR multiple. The moving-average shift is zero. RSI14 uses Wilder gain/loss smoothing, seeded by the first 14 changes; a completely flat gain/loss pair is assigned 50 as an explicit research convention. The first 200 recorded H1 groups are warmup.

CET/CEST source times are converted to UTC. Reading an M1 timestamp as its minute end is an assumption; H1 labelled 07:00 covers (06:00, 07:00]. Empty observations are not filled. Partial recorded groups stay in indicator history, while E, its previous group and C must be complete. Indicator history continues across the year boundary. The two-decimal source cannot supply six-decimal quote precision merely because a calculated mean is displayed that way.

M[t] = SMA20(Close)[t]
U[t] = M[t] × 1.002
L[t] = M[t] × 0.998
RSI14[E] ≤ 30 & RSI14[C] > 30 (long)
RSI14[E] ≥ 70 & RSI14[C] < 70 (short)

3. Reserve the date for its first eligible excursion

Inspect completed H1 endpoints 06:00 through 14:00 UTC inclusive, Monday to Friday. A lower excursion needs Close below its own completed lower band and the previous Close at or above its own lower band; an upper excursion reverses those comparisons. The current and previous groups must each contain 60 consecutive minutes and be one hour apart. Equality is not an outside close.

Take only the first qualifying excursion E that date, in either direction, and freeze its M, U and L. This date is reserved for both models even if confirmation fails or RSI rejects it. The time window is a research convention, not a statement about a local session opening. A later attractive excursion cannot replace the first.

4. Give only the next H1 a re-entry deadline

C is exclusively the complete H1 ending one hour after E. Its Close must be strictly inside the frozen interval L_E to U_E. For a lower excursion it must also remain below M_E; for an upper excursion it must remain above M_E. A return that has already reached or crossed the mean offers no candidate under this definition.

A missing or incomplete next hour cancels the candidate. An outside or boundary-equal Close fails re-entry. No later candle gets another attempt. The independently plotted rolling SMA/envelopes keep updating, while the assessment bands and eventual mean target remain tied to E.

5. Apply the RSI recovery condition to the paired calendar

For a lower excursion, the RSI variant requires unrounded RSI14 at E to be at most 30 and at C strictly above 30. For an upper excursion, it requires RSI at E to be at least 70 and at C strictly below 70. An exact C value of 30 or 70 does not confirm recovery. No divergence, centreline or later crossing is added.

The filtered positions are a strict subset of price-admitted baseline positions, with identical entry, stop, target and path. Only two survive in this sample, both in 2024. In 2025 the filter admits none. An empty period is absence of trading under the rule, not a zero-risk performance record. The first RSI rejection is candidate 10 on 2 February 2024: E has RSI 57.3358, which never met the required upper extreme of 70.

Candidate 10 on 2 February 2024, ending at C 10:00 UTC. E’s RSI 57.3358 did not meet 70, so the RSI model opens no position. No later baseline outcome is borrowed in this decision chart.
Candidate 10 on 2 February 2024, ending at C 10:00 UTC. E’s RSI 57.3358 did not meet 70, so the RSI model opens no position. No later baseline outcome is borrowed in this decision chart.

6. Check the opening quote, rounded target and net room

After C, take the first recorded M1 Open whose interval starts at or after C ends. Cancel a delay over five minutes or an entry at/after 20:00 UTC. For a long, freeze the stop one pip below the lower Low of E and C; for a short, one pip above their higher High. Initial risk is the distance from this opening quote to that stop and must be positive. One USD/JPY pip is 0.01 JPY per USD.

The target starts from M_E and is rounded toward entry: down to a whole pip for a long, up for a short. Freeze it; no later moving mean is substituted. Require (target distance in pips − 2) / initial risk in pips ≥ 1. This locked 2-pip screen is part of admission. A quote that leaves less room is cancelled. The later scenario-cost control does not re-run this screen or create a new calendar.

7. Freeze the exit levels and the holding deadline

Close at the first recorded M1 Open at the earlier of entry plus six elapsed hours and 20:00 UTC that date. While open, a missing minute first makes the path unresolved. Otherwise inspect stop at/beyond the opening quote, then target at/beyond the opening quote, then the time deadline. These are research quote proxies; they do not establish executable Bid/Ask, actual spreads or guaranteed broker fills.

If no opening event closes the position, inspect that minute’s High/Low. One touched level uses that frozen level. Stop and target within the same minute leave the ordering unresolved and receive no invented return. Range exits are disclosed as minute intervals. An opening quote exactly equal to the stop is not proof of an adverse-price gap. No lots, pyramiding or moving stop is simulated.

Real M1 detail of the first 2024 intraminute protective stop: baseline position 2. RSI rejected that position. The 146.79 stop is touched in the 13:30–13:31 UTC interval on 2 February; the exact execution second is unknown.
Real M1 detail of the first 2024 intraminute protective stop: baseline position 2. RSI rejected that position. The 146.79 stop is touched in the 13:30–13:31 UTC interval on 2 February; the exact execution second is unknown.

8. Walk through the first baseline position

Candidate 3 is a short on 16 January 2024. E ends at 06:00 UTC with Close 146.15, above its upper band 146.128173. Its frozen mean is 145.836500. C ends at 07:00 with Close 146.08, inside the frozen upper half. The next observed opening quote is 146.07, not C’s Close. The higher E/C High is 146.25, giving a 146.26 stop; the mean target rounds upward to 145.84. Risk is 19 pips, target distance 23 pips and screened net room 21/19 = 1.1053 R.

RSI falls from 75.9394 to 69.9762, so both models admit the position. The recorded 08:34 UTC opening quote equals the stop. Gross result is −19 pips and net at the stated 2-pip allowance is −21/19 = −1.1053 R. The entry image stops at 07:00; the separate completed image stops at 08:34. E/C/I/X mean excursion, confirmation, entry and exit. The later M1 stop detail concerns baseline position 2, which RSI rejected; it is a separate retrospective illustration.

The same first position through 16 January 2024 08:34 UTC. That recorded opening quote equals the 146.26 stop. At 2 pips total cost, net result is −21/19 = −1.1053 R. This is not evidence of a worse-price opening gap.
The same first position through 16 January 2024 08:34 UTC. That recorded opening quote equals the 146.26 stop. At 2 pips total cost, net result is −21/19 = −1.1053 R. This is not evidence of a worse-price opening gap.

9. Count every cancellation alongside the positions

The calendar has 303 first daily excursions. Of those, 221 fail the immediate re-entry, 45 leave less than the required net target room and 5 have already reached or crossed the mean at confirmation. The other 32 enter Base; RSI keeps 2 and excludes 30. Candidates and entered trades are different counts. The full CSV preserves each first event and its decision.

All 32 entered paths resolve in these inputs. None needs a guessed missing-minute or same-minute stop/target outcome. The unresolved rules remain part of the frozen method for other data. This does not imply that all market hours are complete: only 12372 of the 12530 recorded H1 groups contain all 60 minutes.

Decision / cancellationCandidates
Immediate next candle failed frozen-band re-entry221
Mean already reached or crossed at confirmation5
Less than 1R net room at the locked 2-pip screen45
Missing or incomplete confirmation hour0
Admitted entry32

10. Read the annual split and the empty RSI year

At 2 pips total cost per position, the 16 baseline trades in 2024 sum to +0.78 R and the 16 in 2025 to −0.94 R, giving −0.16 R combined. RSI’s two retained trades sum to −2.36 R; neither wins. It has zero 2025 entries. The table therefore uses dashes for the empty RSI period’s return, profit factor and drawdown instead of presenting empty-set zeros as performance.

Before the scenario cost deduction, the baseline sums to +4.19 R; at 2 pips it is −0.16 R. This illustrates sensitivity to the allowance, not a profitable validation. Thirty-two positions and especially two filtered positions support no robust inference about future returns. The unchanged 2025 calculation is not unseen-data testing or live forward trading. Closed-position R drawdown omits intratrade changes and is not account drawdown.

Resolved positions only. The RSI sample is just 2 trades; 2025 has none. Dashes for an empty period are not zero-risk performance.

Assumed total cost per completed trade · pips: 2.0 pip.

PeriodModelEnteredResolvedUnresolvedNet RProfit factorClosed-trade drawdown · R
2024Base16160+0.781.083.63
2024RSI220-2.360.002.36
2025Base16160-0.940.916.99
2025RSI
No entries in this period; no performance estimate
000———
2024 + 2025Base32320-0.160.996.99
2024 + 2025RSI220-2.360.002.36
Cumulative closed-position net R at a fixed 2-pip scenario: 32 baseline positions and only 2 retained RSI positions on the same calendar. Both RSI positions are in 2024; none is in 2025. These sums are not account equity or evidence of an edge.
Cumulative closed-position net R at a fixed 2-pip scenario: 32 baseline positions and only 2 retained RSI positions on the same calendar. Both RSI positions are in 2024; none is in 2025. These sums are not account equity or evidence of an edge.

11. Separate the locked room screen from scenario costs

Admission was calculated once with a fixed 2-pip screening allowance. The explorer’s 0–8-pip control, in 0.5 steps, is a separate total round-trip cost scenario: net pips = gross pips − scenario cost; net R = net pips / initial risk pips. The standard comparisons use 0/1/2/3/5 pips. These assumptions are not measured spread, commission, slippage or financing charges.

Changing the scenario updates the selected net result and study table, while the recorded price series, first-event calendar, RSI admission, stop and target stay fixed. A higher scenario can make the original net-room threshold fail retrospectively; this control does not then re-screen or replace the trade. Static figures and their cumulative R curve explicitly use 2 pips. R sums are trade-unit sums, not compounded or cash returns.

12. Inspect the decision before unfolding the path

Choose any of the 303 candidates, then Base or RSI and At decision or Complete path. Shortcuts select the named case and its model, starting in decision mode. At decision hides later candles, exit and realized result, including the formula. For a rejected RSI position it ends at C, draws no admitted position and disables Complete path. Select Base explicitly to inspect its separate admitted trade.

Complete path is available only for an admitted position. The last H1 uses only source minutes through the disclosed information cutoff and can be partial or an opening point alone. The cost panel places net R next to the control. Compare the disclosed cutoff with the last plotted observation. Use the inputs and protocol to investigate separately on demo; this small study does not validate deployment with real funds.

Frequently asked questions

Is 0.20 an ATR multiplier or a 20% envelope?

Neither. The fixed deviation is 0.20%, so the fraction is 0.002. The model uses SMA20 of Close and no horizontal shift.

Are the confirmation bands and target allowed to move?

No. They are frozen from the excursion E. The target is its mean rounded toward entry to a whole pip. The rolling channel is plotted separately for context.

Which RSI crossing does this study require?

A lower excursion requires RSI_E ≤ 30 and RSI_C > 30; an upper excursion requires RSI_E ≥ 70 and RSI_C < 70. C is only the immediate next complete H1.

Does a zero-trade 2025 prove that the RSI filter is safer?

No. It means the filtered model has no admitted positions in that period. An empty sample cannot establish drawdown, profitability or safety.

Why does changing costs not cancel or replace entries?

The entry room screen was locked at 2 pips before the replay. The slider is a separate outcome-cost scenario on the same calendar, not a new execution or rescheduling model.

What if a minute touches both target and stop?

Its within-minute order is not known. The protocol leaves the path unresolved and assigns no return. No such unresolved entered path occurs in this particular input.

Data, calculation method and scope

The 733 verified original Forexite daily ZIPs provide 751488 USD/JPY minute observations and 12530 UTC H1 groups, including 12372 complete groups. Prices have two source decimals. CET/CEST is converted to UTC; minute-end labels are a declared assumption. Gaps are not filled and partial recorded groups remain in indicator history. Quote observations are not documented broker executions.

The frozen protocol and input hash were saved before the first calculation. A separate SQLite and 48-digit Decimal implementation confirmed the 12530 groups, indicator histories, 303 event decisions and 32 trade paths. The self-contained download includes all minute inputs, source hashes, the protocol, replay, expected output and both CSV ledgers. It needs no extra raw downloads; the agreement verifies this calculation on these inputs, not a trading edge.

Primary references