OPEN-SOURCE SCRIPT
EMA-RSI-MACD-Volume-Candle Combo HÂN HÂN

//version=5
indicator("EMA-RSI-MACD-Volume-Candle Combo", overlay=true)
// === EMA 20 & 50 ===
ema20 = ta.ema(close, 20)
ema50 = ta.ema(close, 50)
goldenCross = ta.crossover(ema20, ema50) // EMA20 cắt lên EMA50
plot(ema20, color=color.yellow, title="EMA 20")
plot(ema50, color=color.orange, title="EMA 50")
// === RSI (14) ===
rsi = ta.rsi(close, 14)
rsiCondition = rsi <= 30
// === MACD ===
macd = ta.ema(close, 12) - ta.ema(close, 26)
signal = ta.ema(macd, 9)
macdCondition = macd > 0
// === Volume breakout ===
volMA = ta.sma(volume, 20)
volCondition = volume > volMA * 1.5 // Volume > 150% so với MA20
// === Candlestick reversal patterns ===
// Bullish Engulfing
bullEngulf = close[1] < open[1] and close > open and close >= open[1] and open <= close[1]
// Hammer
hammer = (close > open) and ((high - low) > 3 * (open - close)) and ((close - low) / (0.001 + high - low) > 0.6)
candleCondition = bullEngulf or hammer
// === Combined Signal ===
buySignal = goldenCross and rsiCondition and macdCondition and volCondition and candleCondition
// Plot signals on chart
plotshape(buySignal, title="BUY Signal", style=shape.labelup, color=color.green, text="BUY", location=location.belowbar, size=size.large)
// Alerts
alertcondition(buySignal, title="BUY Signal Alert", message="EMA20>EMA50 + RSI≤30 + MACD>0 + Volume Breakout + Reversal Candle")
indicator("EMA-RSI-MACD-Volume-Candle Combo", overlay=true)
// === EMA 20 & 50 ===
ema20 = ta.ema(close, 20)
ema50 = ta.ema(close, 50)
goldenCross = ta.crossover(ema20, ema50) // EMA20 cắt lên EMA50
plot(ema20, color=color.yellow, title="EMA 20")
plot(ema50, color=color.orange, title="EMA 50")
// === RSI (14) ===
rsi = ta.rsi(close, 14)
rsiCondition = rsi <= 30
// === MACD ===
macd = ta.ema(close, 12) - ta.ema(close, 26)
signal = ta.ema(macd, 9)
macdCondition = macd > 0
// === Volume breakout ===
volMA = ta.sma(volume, 20)
volCondition = volume > volMA * 1.5 // Volume > 150% so với MA20
// === Candlestick reversal patterns ===
// Bullish Engulfing
bullEngulf = close[1] < open[1] and close > open and close >= open[1] and open <= close[1]
// Hammer
hammer = (close > open) and ((high - low) > 3 * (open - close)) and ((close - low) / (0.001 + high - low) > 0.6)
candleCondition = bullEngulf or hammer
// === Combined Signal ===
buySignal = goldenCross and rsiCondition and macdCondition and volCondition and candleCondition
// Plot signals on chart
plotshape(buySignal, title="BUY Signal", style=shape.labelup, color=color.green, text="BUY", location=location.belowbar, size=size.large)
// Alerts
alertcondition(buySignal, title="BUY Signal Alert", message="EMA20>EMA50 + RSI≤30 + MACD>0 + Volume Breakout + Reversal Candle")
오픈 소스 스크립트
진정한 트레이딩뷰 정신에 따라 이 스크립트 작성자는 트레이더가 기능을 검토하고 검증할 수 있도록 오픈소스로 공개했습니다. 작성자에게 찬사를 보냅니다! 무료로 사용할 수 있지만 코드를 다시 게시할 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
이 정보와 게시물은 TradingView에서 제공하거나 보증하는 금융, 투자, 거래 또는 기타 유형의 조언이나 권고 사항을 의미하거나 구성하지 않습니다. 자세한 내용은 이용 약관을 참고하세요.
오픈 소스 스크립트
진정한 트레이딩뷰 정신에 따라 이 스크립트 작성자는 트레이더가 기능을 검토하고 검증할 수 있도록 오픈소스로 공개했습니다. 작성자에게 찬사를 보냅니다! 무료로 사용할 수 있지만 코드를 다시 게시할 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
이 정보와 게시물은 TradingView에서 제공하거나 보증하는 금융, 투자, 거래 또는 기타 유형의 조언이나 권고 사항을 의미하거나 구성하지 않습니다. 자세한 내용은 이용 약관을 참고하세요.