PROTECTED SOURCE SCRIPT

SHALOM TRADING HUB – Bollinger Band System

47
SHALOM TRADING HUB – Bollinger Band System (Strategy)

All-in-one BB system with both Breakout and Mean-Reversion modes.
Automatic ENTRY / EXIT / STOP-LOSS, optional Mid-Band Exit, ATR or % risk, and built-in alerts. Backtest-ready.

What it does

Bollinger Bands: Basis = SMA(length); Upper/Lower = ±(mult × StDev).

Signals

Breakout mode

LONG → price crosses above Upper

SHORT → price crosses below Lower

Mean-Reversion mode

LONG → price re-enters above Lower

SHORT → price re-enters below Upper

Risk / Exits

ATR mode: SL = ATR × Mult, TP = SL × Risk:Reward

% mode: SL = %Stop, TP = %Take Profit

Optional Mid-Band (Basis) cross exit.

Visuals: BB lines + active Entry / SL / TP overlays + last-bar price labels.

Alerts: Breakout / Mean-Reversion signals and TP/SL hits.

Inputs (Settings)

Source, Length, Multiplier – BB calculation.

Signal Mode – Breakout or Mean Reversion.

Use ATR Stop/Target? – On = ATR; Off = %.

ATR Length, ATR Mult (SL), Risk:Reward (TP)

% Stop, % Take Profit (when ATR is Off)

Also exit on Mid-Band cross? – On/Off.

Alerts only on bar close? – Filters to confirmed bars.

Entry / Exit / Stop

Entry: Auto when the chosen signal condition triggers.

Stop-Loss: Placed from ATR or % settings.

Take-Profit: Set by R:R or % settings.

Mid-Band Exit (optional):

LONG → exit if close < Basis

SHORT → exit if close > Basis

Alerts (How-to)

Add the strategy to the chart → click Alerts (⚠️).

Condition: “SHALOM BB System” → choose:

BB Breakout LONG / SHORT

BB Mean-Reversion LONG / SHORT

Long TP Hit / Long SL Hit / Short TP Hit / Short SL Hit

Choose Once per bar or Once per bar close.

Backtest Tips

Match timeframe to your instrument.

Tune ATR/Mult, R:R, % to volatility.

Session filter (e.g., 09:20–15:20 IST) can be added easily in code.

Default pyramiding = 0; raise if you want multiple entries.

Exención de responsabilidad

La información y las publicaciones que ofrecemos, no implican ni constituyen un asesoramiento financiero, ni de inversión, trading o cualquier otro tipo de consejo o recomendación emitida o respaldada por TradingView. Puede obtener información adicional en las Condiciones de uso.