OPEN-SOURCE SCRIPT

EMA COLOR BUY SELL

50

indicator("Sorunsuz EMA Renk + AL/SAT", overlay=true)

length = input.int(20, "EMA Periyodu")
src = input.source(close, "Kaynak")


emaVal = ta.ema(src, length)

isUp = emaVal > emaVal[1]
emaCol = isUp ? color.green : color.red

plot(emaVal, "EMA", color=emaCol, linewidth=2)

buy = isUp and not isUp[1] // kırmızı → yeşil
sell = not isUp and isUp[1] // yeşil → kırmızı

plotshape(buy, style=shape.arrowup, location=location.belowbar, color=color.green, size=size.large, text="AL")
plotshape(sell, style=shape.arrowdown, location=location.abovebar, color=color.red, size=size.large, text="SAT")
alertcondition(buy, "EMA AL", "EMA yukarı döndü")
alertcondition(sell, "EMA SAT", "EMA aşağı döndü")

免責事項

この情報および投稿は、TradingViewが提供または推奨する金融、投資、トレード、その他のアドバイスや推奨を意図するものではなく、それらを構成するものでもありません。詳細は利用規約をご覧ください。