INVITE-ONLY SCRIPT
Atualizado

Reversal iJung v2

43
Reversal iJung v2 User Guide
1. Concept

Reversal iJung v2 is a trend-filtered reversal entry tool with:

Trend filter using EMA 20/50/200 (+ EMA cluster)

Candle pattern confirmation (Engulfing / Pin bar)

“Body over EMA20” logic for valid signals

Retrace-based Pending Entry (Limit style)

Auto Lot, RR-based exits, dashboard, and webhook alerts to Telegram

Objective: pick high-quality reversals in line with the major trend, enter with better RR via retrace, and manage risk clearly.

2. Core Components
2.1 EMA Trend Filter & Cluster

EMA20 / EMA50 / EMA200 define:

Bull trend: 20 > 50 > 200

Bear trend: 20 < 50 < 200

useTrendFilter:

On: only trade in trend direction

Off: ignore trend

EMA Cluster Mode

"Off": no cluster filter

"2 EMA (Fast/Mid)": EMA20 & EMA50 must stay within Max EMA Distance (x ATR)

"3 EMA (Fast/Mid/Slow)": EMA20/50/200 all clustered

This helps avoid messy conditions where EMAs are too wide or choppy.

2.2 MACD Weakness Filter

Long: accept only if selling pressure weakens:

macdLine < 0 and macdHist > macdHist[1]

Short: accept only if buying pressure weakens:

macdLine > 0 and macdHist < macdHist[1]

useMacdFilter = On/Off

2.3 Entry Logic & Retrace Mode

Patterns

Bull/Bear Engulfing

Bull/Bear Pin bar (with adjustable body/wick percentages)

Optional: “Any candle that closes over EMA20” as a signal

Body over EMA20

Long: candle body crosses EMA20 and closes above it

Short: body crosses EMA20 and closes below it

Entry Mode

"Close": entry at bar close

"Retrace":

Long: use close → low distance

Short: use high → close distance

EntryRetrace % controls how deep to place Limit entry

SL = swing low/high ± slBufferPts * mintick
TP1 / TP2 set by RR (1:rr1, 1:rr2)

2.4 Exit Logic

Normal exits:

Hit TP1, TP2, or SL

Track RR1 / RR2 statistics and total RR

EMA Exit:

Long exit when price closes below EMA20 with a bearish candle

Short exit when price closes above EMA20 with a bullish candle

Reason code: LONG_EMA_EXIT / SHORT_EMA_EXIT

2.5 Pending & Expiry

Only one side active at a time (no hedge).

minBarsBetweenSignals: lockout between signals to avoid spam.

pendingExpireBars: if price hasn’t touched entry within X bars, cancel pending and send *_PENDING_EXPIRED alert.

2.6 Auto Lot

Estimate lot size from:

Account Balance

Risk % per trade

Value per point per 1 lot

Then:

Lot ≈ (Balance × Risk%) / (|Entry – SL| × valuePerPointPerLot)

A label Lot≈... is shown near the entry line.

2.7 Dashboard

Modes: Normal, Compact, Mini

Mini mode shows:

Trend / Lot / Entry / SL / TP1 / TP2 / R1/R2 win%

Position options:

Top Right, Top Left, Bottom Right, Bottom Left

3. Alerts & Webhook

The script uses alert() with a JSON payload when useWebhook is enabled.

Key reasons:

ENTRY_SIGNAL → new pending (for placing Limit orders)

ENTRY_FILLED → order filled

LONG_SL, SHORT_SL, LONG_TP2, SHORT_TP2

LONG_EMA_EXIT, SHORT_EMA_EXIT

LONG_PENDING_EXPIRED, SHORT_PENDING_EXPIRED

Your Google Apps Script parses this JSON, builds a nice human-readable message, and forwards it to Telegram.

4. Telegram Flow (Short English Summary)

Create Telegram bot via BotFather → get BOT_TOKEN.

Get CHAT_ID of your group/channel.

Create Google Apps Script project, paste the provided code, set token + chat id.

Deploy as Web App (Anyone).

Use that Web App URL as Webhook URL in TradingView alert.

In TradingView:

Condition: Reversal iJung v2 → Any alert() function call

Leave message empty (the script generates JSON)

Enable Webhook + paste URL

Now you’ll receive:

Yellow (ENTRY_SIGNAL): to pre-place Limit orders

Green/Red (ENTRY_FILLED): when position is live

Exit / Cancel / EMA Exit notifications with full price details
Notas de Lançamento
Update : Alert Pending Order
Notas de Lançamento
Update : X Signal when SL

Aviso legal

As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.