CISD CSD + OB & BB Indicator: Sweep, Block, Breaker Retest

Written by Dominic Walsh · Published · Last updated

The cisd csd + ob & bb indicator follows one sequence from start to finish. Price sweeps a prior extreme, closes back inside, and that change of state gets marked. The candle that began the move becomes a block, and if price later breaks through it, the tool waits for the retest from the other side.

This build ships as a compiled .ex4 for MT4 and .ex5 for MT5; the screenshots below come from EURUSD H1.

Platforms MT4 (.ex4) + MT5 (.ex5)
Chart window Main price chart
Plots 4: CISD Bullish, CISD Bearish, BB Bullish Retest, BB Bearish Retest
Alerts popup, push notification, email, sound
Inputs 17

What the CISD CSD + OB & BB Indicator draws on the chart

CISD Bullish marks the bar that swept a prior low and closed back above it.

CISD Bearish marks the mirror case above a prior high.

BB Bullish Retest fires when price returns into a block that has already broken downward.

BB Bearish Retest is the same on the other side.

Rectangle objects draw each active zone, filled when FillZones stays on.

  • CISD Bullish: arrow, lime, width 2, arrow code 233
  • CISD Bearish: arrow, red, width 2, arrow code 234
  • BB Bullish Retest: arrow, dodger blue, width 2, arrow code 233
  • BB Bearish Retest: arrow, orange, width 2, arrow code 234
EURUSD H1: the cisd csd + ob & bb indicator marking CISD Bullish after a sweep.
EURUSD H1: the cisd csd + ob & bb indicator marking CISD Bullish after a sweep.

How the CISD CSD + OB & BB Indicator calculates its values

Finding the sweep

PivotLeft and PivotRight qualify a pivot the usual way, and SweepLookback sets how far back the code searches for one to sweep.

A bullish change of state needs three things on one bar: the low went under that prior low, the close came back above it, and the candle finished up. Taking the level and rejecting it is the event, not simply reaching it.

Locating the origin block

Once a sweep confirms, the code walks backwards for the last candle that closed down. That candle is the origin of the move.

Its zone runs from the higher of its open and high down to the lower of its close and low, so the whole candle body and the relevant wick sit inside the block.

Break, then retest

Each block stays tracked until a later close pushes clean through its far edge. At that point the code marks it broken rather than deleting it.

A broken block becomes a breaker. When price returns and trades back into that same zone from the other side, the retest buffer marks the bar. MaxActiveBlocks caps how many stay tracked at once.

How to read the signals

A change of state marker says a level got taken and rejected inside one bar, which is a different event from a clean break.

Zones drawn behind price are the origin candles, not support drawn by hand.

A retest marker only appears on a block that already broke, so the level has flipped sides by then.

Old zones drop out of tracking once MaxActiveBlocks fills, so the newest structure crowds out the oldest.

Alert channels in this build: popup, push notification, email and sound, one message per closed bar.

Alerts cover popup, push, email and sound. A bar time check runs first, so one event produces one alert per closed bar.

Every CISD CSD + OB & BB Indicator input

Core settings

Setting What it does Default
PivotLeft Bars left of pivot. PivotLeft is how many older bars a pivot has to beat. It defaults to 3. 3
PivotRight Bars right of pivot. PivotRight is the confirmation window in front of a pivot, also 3, and it sets how long the tool waits before accepting one. 3
SweepLookback Max bars to look back for swept pivot. SweepLookback is how far back the search for a level to sweep reaches, 50 bars by default. 50
MaxActiveBlocks Concurrent OB tracker capacity per side. MaxActiveBlocks caps how many zones stay tracked at once, 6 by default. 6
ZoneRightBars Bars to extend each zone rightwards. ZoneRightBars is how far a drawn zone extends to the right, 50 bars by default. 50
FillZones Fill OB/BB rectangles. FillZones shades each rectangle rather than outlining it. It defaults to true. on
ObjectPrefix (see inputs panel) CISD_OB_BB_

Display settings

Setting What it does Default
BullOBColor (see inputs panel) sea green
BearOBColor (see inputs panel) indian red
BullBreakerColor (see inputs panel) dodger blue
BearBreakerColor (see inputs panel) orange

Alert settings

Setting What it does Default
EnableAlerts (see inputs panel) on
EnablePopup (see inputs panel) on
EnablePushNotify (see inputs panel) off
EnableEmail (see inputs panel) off
EnableSound (see inputs panel) off
SoundFile (see inputs panel) alert.wav
Inputs panel for the cisd csd + ob & bb indicator showing PivotLeft and SweepLookback.
Inputs panel for the cisd csd + ob & bb indicator showing PivotLeft and SweepLookback.

Settings that fit your chart

The screenshot uses EURUSD H1. This sequence needs swings with room in them, so H1 and H4 give the pivot search something real to work with. On M1 and M5 a three bar pivot qualifies inside ordinary noise and the zone count fills immediately. Raising PivotLeft and PivotRight together is the usual fix.

When the CISD CSD + OB & BB Indicator fails

A pivot needs PivotRight closed bars before it counts, so the level a sweep refers to only confirms several bars after forming.

Walking back for the last opposite candle finds one candle, while a genuine origin often spans several.

Nothing measures how far a break travelled. A close one point past the edge marks a block broken exactly like a decisive one.

MaxActiveBlocks at 6 drops older structure from tracking whether or not price ever returned to it.

Copy the compiled CISD CSD + OB & BB Indicator file into your MQL4/Indicators folder, and the MT5 build into MQL5/Indicators, then restart the terminal and drag it onto a chart. The step-by-step guide with screenshots is at how to install MT4 and MT5 indicators.

Background reading on the method behind the CISD CSD + OB & BB Indicator: Bond market on Wikipedia, Standarddeviation at Investopedia.

Download the CISD CSD + OB & BB Indicator for MT4 and MT5

The zip holds the compiled CISD CSD + OB & BB Indicator build for MT4 and MT5, plus a short README. Compiled files only, no source. Enter your email below and the download link arrives in your inbox.

Download this indicator free

Enter your email and the file is yours. You also get the full MT4 and MT5 library.

  • 1,380+ indicators
  • MT4 and MT5 files
  • No spam, unsubscribe any time

FAQ

What has to happen on a bar for CISD Bullish to print?

Three conditions on the same bar. The low has to trade under a prior pivot low found within SweepLookback, the close has to finish back above that low, and the candle has to close up. Reaching the level is not enough; the bar has to reject it and close on the other side.

Which candle becomes the block after CISD Bullish prints?

After a bullish change of state it walks backwards to the most recent candle that closed below its open. That candle is treated as the origin of the move, and the zone spans from the higher of its open and high to the lower of its close and low.

What turns a block into a BB Bullish Retest?

A later close pushing clean through its far edge. The block is not removed at that point, it gets marked as broken. If price then returns into the same zone from the opposite side, the retest buffer marks that bar.

Why does PivotRight delay everything by three bars?

A pivot only qualifies once PivotRight closed bars sit to its right without beating it. At the default of 3 a level confirms three bars after it formed. That costs you delay, and it buys a level that does not disappear on the next candle.

Are results guaranteed?

No. Trading involves risk. Results are not guaranteed; past performance is not indicative of future results. Use the CISD CSD + OB & BB Indicator as one input. Always backtest before trading live.

Category: this is part of our Signal and Forecast collection. Also, browse more Signal and Forecast for MetaTrader, or explore every MT4 indicator and MT5 indicator on the site.

External references

Dominic Walsh - Forex trader and MT4/MT5 developer

About the author

Written by Dominic Walsh, a Forex trader and MT4/MT5 indicator, Expert Advisor and script developer. Every tool on forexmt4systems.com is tested on live charts before release and ships with ready-to-use compiled MT4 (.ex4) and MT5 (.ex5) files. Learn more about the trader and developer behind this site.

How we build, test and correct every tool: Editorial & Testing Policy. Trading carries risk; see the disclaimer.

Leave a Comment