OPEN-SOURCE SCRIPT

Day Trading (Indicator) - EMA/RSI/VWAP/Breakout

360
Indicator Overview
This script is a TradingView Indicator that generates Long (buy) entry signals based on the alignment of:

Trend filter (EMA)
Momentum filter (RSI)
Entry trigger (either Breakout + Volume OR VWAP Retest)
Chart visualization (labels + optional candle coloring)
Alert condition for TradingView notifications 13
1) Trend Filter (EMA)
The script calculates two exponential moving averages:

EMA Fast
EMA Slow
A long setup requires:

close > emaFast
emaFast > emaSlow
This means price is above the fast EMA and the fast EMA is above the slow EMA → bullish trend.

2) Momentum Filter (RSI)
It calculates RSI and requires:

RSI > rsiMid
Default midline is 50, but you can adjust it in inputs.

3) Two Possible Entry Triggers
The script allows entries using one of these two conditions (or both, depending on your settings):

A) Breakout + Volume Filter
It checks whether the current candle closes above the highest high of the previous brkLen bars:

breakUp = close > highestPrev
And it also requires a volume confirmation:

volume > SMA(volume, volLen) * volMult
You control this trigger using:

useBreakout
B) VWAP Retest Trigger
It looks for a VWAP retest behavior:

Candle low touches or goes below VWAP: low <= vwapVal
Then candle closes above VWAP: close > vwapVal
You control this trigger using:

useVWAPRetest
4) Final Long Signal Logic
A Long Entry signal is generated only when ALL trend + momentum conditions are true:

trendUp AND rsiOkUp AND ( Breakout condition OR VWAP retest condition )
5) Visual Output on the Chart
When longEntry becomes true:

The script draws a “دخول” (Entry) label on the chart
It colors the candle black for the signal bar
6) Alerts (TradingView)
The line below defines the alert trigger:

pinescript
alertcondition(longEntry, title="Long Entry", message="دخول LONG: شروط المضاربة اليومية متحققة")
Important:
To actually receive notifications, you must create an alert from TradingView:

Alerts → Create Alert
Choose this script’s “Long Entry” condition

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.