Strategy · Pine Script v5 · On the chart

Unicorn Strategy

by oscar811

This overlay strategy marks market-structure swings and breaker blocks on the price chart.

View on GitHub

GitHub stars3on the repository
Pine versionv5runs as is
Lines of code791
Settings24inputs
LicenceNone stated
Last update2 years ago27 Feb 2024

Add It to Your TradingView Chart

  1. 1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
  2. 2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
  3. 3Paste over the templateCreate a new strategy, select all of the template text and paste. Press Save and give it a name.
  4. 4Add it to the chartPress Add to chart. The trades and results appear in the Strategy Tester tab; adjust the settings with the gear icon.

Source Code

The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.

Overview

Unicorn Strategy can limit a breaker to the candle body, use one or two candles in the same direction, and stop the block at the first break of its center line. Entries can be restricted to when price is inside a premium or discount array, and those zones, swing lines, and swing breaks can be shown or hidden. Optional take-profit targets use three reward-to-risk ratios. No stop-loss input appears in the provided settings, and pyramiding is off.

Details

Published by

oscar811 on GitHub

Draws

On the price chart

Markets

Any symbol

Timeframes

Any timeframe

Risk Notes

  • The strategy enters trades without a stop loss

Settings

The inputs you can change from the gear icon on the chart. Defaults are the author's.

SettingTypeDefaultVariable
Lengthint5len
Use only candle bodyboolfalsebreakerCandleOnlyBody
Use 2 candles instead of 1boolfalsebreakerCandle_2Last
Stop at first break of center linebooltruetillFirstBreak
Only when E is in Premium/Discount ArrayboolfalseonlyWhenInPDarray
show Premium/Discount ZoneboolfalseshowPDarray
Highlight Swing BreaksboolfalseshowBreaks
Show Swings/PD ArraysbooltrueshowSPD
Text Colorcolorcolor.silverPDtxtCss
Swing Line Colorcolorcolor.silverPDSCss
Enable TPboolfalseiTP
tpCsscolor#2157f3tpCss
Show all 24 settings
SettingTypeDefaultVariable
R:R 1float1R1a
:float2R2a
R:R 2float1R1b
:float3R2b
R:R 3float1R1c
:float4R2c
colorcolor.rgb(12, 181, 26, 93)cBBplusA
cBBplusBcolorcolor.rgb(12, 181, 26, 85)cBBplusB
colorcolor.rgb(255, 82, 82, 85)cSwingBl
colorcolor.rgb(255, 17, 0, 95)cBB_minA
cBB_minBcolorcolor.rgb(255, 17, 0, 85)cBB_minB
colorcolor.rgb(0, 137, 123, 85)cSwingBr
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.

Similar Pine Scripts

6 stars

This strategy combines Opening Range Breakout (ORB) mechanics with Inner Circle Trader (ICT) concepts like Fair Value Gaps, Order Blocks, and liquidity grabs. It identifies session opening ranges and generates signals when price breaks out with supporting rela

Strategy v5 BreakoutSMC / ICT / price action
Updated 7 months ago · None stated GitHub repository of Advanced ORB + ICT Strategy

Qtus SMC-Sniper AutoTrader v2 is an automated trading strategy plotted on the price chart that combines Smart Money Concepts (SMC), ICT frameworks, price action patterns, and technical indicators into a multi-factor scoring engine. It enters long or short posi

Strategy v6 SMC / ICT / price actionTrend
Updated 2 months ago · Custom licence GitHub repository of Qtus SMC-Sniper AutoTrader v2

Booming Bulls Sniper

by jayadevrana
1 stars

Implements liquidity sweep and prop firm breakout strategies inspired by the Booming Bulls methodology. The script monitors previous-day, previous-week, and current-day highs and lows for liquidity sweeps where price wicks beyond a level without closing past i

Strategy v6 SMC / ICT / price actionSupport & resistance
Updated 4 days ago · MPL-2.0 GitHub repository of Booming Bulls Sniper
1 stars

This strategy plots market structure on the price chart from confirmed swing highs and lows and flags breaks of those levels. Breaks can use the wick or the close, and structure logic can stay standard or include sweeps. ChoCH mode selects Ping, Verify, or bot

Strategy v6 SMC / ICT / price actionSupport & resistance
Updated 4 days ago · None stated GitHub repository of CHOCH-Strategy (Structure Only)

ORB + ICT Backtest Strategy v2

by mccallister-dev
1 stars

This strategy defines opening range breakouts within Asian, London and New York sessions using ATR-based width and buffer filters. It identifies potential entries on breakout after a retest followed by continuation, applying ICT-style context and SMC proxies f

Strategy v6 BreakoutSMC / ICT / price action
Updated 5 weeks ago · None stated GitHub repository of ORB + ICT Backtest Strategy v2
1 stars

This Pine Script v6 strategy isolates and tests market structure events, specifically Break of Structure (BOS) and Change of Character (CHoCH). Using swing points calculated from configurable pivot strength settings, it tracks structural direction and triggers

Strategy v6 SMC / ICT / price actionBreakout
Updated 7 days ago · Apache-2.0 GitHub repository of Parity Probe 02 - CHoCH/BOS Isolator

More SMC / ICT scripts

Related on ForexR

Trade Your Charts With a Regulated Broker

Compare brokers that connect to TradingView, with spreads, minimum deposits and leverage side by side.

Compare brokers