OPEN-SOURCE SCRIPT

ICT Unicorn Strategy [RoboQuant]

438
What it detects

Structure: uses pivots (ta.pivothigh/low) to build a mini zigzag (A–B–C–D).

“Unicorn” Pattern:

Bull: bullish direction, C below A (protected swing), with a bullish “BRB” candle at B.

Bear: mirrored version.

FVG: searches for a valid gap between candle i and i+2 inside the BRB candle range and greater than 0.05 × ATR (quality filter).

When an FVG appears, it plots boxes/lines (top/bottom of range, protected swing, FVG box).

How it enters

Bull Trigger: a candle opens inside the FVG and closes above the top of the FVG (mitigation + continuation).

SL = protected swing (firstBl.swing, pivot C).

TP = top + (top - swing) * (reward/risk).

Draws Risk and Reward boxes if showTargets=true.

Bear Trigger: mirror setup (opens inside FVG and closes below bottom).

Management & sizing

Sizing: calculates position size = riskAmount / SL distance, capped by maxPositionSize.

RR configurable with risk and reward (default 1:2).

Trailing optional: adjusts TsL using short pivots (lenS).

Trade closes at SL (break of swing) or TP (target reached).

combine: if false, a bull setup cancels a bear setup (and vice versa). If true, both can coexist.

Key parameters

len: pivot sensitivity (structure).

riskAmount and maxPositionSize: risk control.

trail, lenS: trailing logic.

Box colors/visibility (showTargets, colRisk, colReward).

ICT translation

Seeks impulse → FVG → pullback into FVG → expansion, with a protected swing (implicit BOS/MSS via zigzag) and mitigation of imbalance.

The ATR * 0.05 filter avoids micro-gaps without intent.

How I’d use it (quick checklist)

Mark HTF bias (only take bull or bear setups with the trend).

On LTF, wait for a valid FVG inside the BRB candle.

Enter only if a candle re-enters the FVG and closes breaking its edge.

SL at swing C, TP by RR (default 1:2).

Enable trailing only after 1R is reached (optional, tuned via lenS).

Feragatname

Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.