PROTECTED SOURCE SCRIPT
نصي البرمجي

//
version
=5
indicator("Multi Indicator Template - Stoch, MACD, Donchian, SMI, EMA, Volume", overlay=true)
// 1. EMA (متوسط متحرك أسي)
show_ema = input(true, title="Show EMA")
ema_length = input.int(14, title="EMA Length")
ema_val = ta.ema(close, ema_length)
plot(show_ema ? ema_val : na, color=color.blue, title="EMA")
// 2. Donchian Trend Ribbon
show_donchian = input(true, title="Show Donchian Trend Ribbon")
donchian_length = input.int(20, title="Donchian Length")
donchian_upper = ta.highest(high, donchian_length)
donchian_lower = ta.lowest(low, donchian_length)
donchian_mid = (donchian_upper + donchian_lower) / 2
donchian_trend = close > donchian_mid ? 1 : close < donchian_mid ? -1 : 0
bgcolor(show_donchian ? (donchian_trend == 1 ? color.new(color.green, 85) : donchian_trend == -1 ? color.new(color.red, 85) : na) : na, title="Donchian Trend Ribbon")
// 3. Stochastic Oscillator
show_stoch = input(true, title="Show Stochastic")
stoch_k_len = input.int(14, title="Stoch K Length")
stoch_d_len = input.int(3, title="Stoch D Length")
k = ta.stoch(close, high, low, stoch_k_len)
d = ta.sma(k, stoch_d_len)
plot(show_stoch ? k : na, color=color.purple, title="Stoch %K")
plot(show_stoch ? d : na, color=color.orange, title="Stoch %D")
hline(20, "Oversold", color=color.gray)
hline(80, "Overbought", color=color.gray)
// 4. MACD
show_macd = input(true, title="Show MACD")
[macdLine, signalLine, hist] = ta.macd(close, 12, 26, 9)
macd_hist_plot = plot(show_macd ? hist : na, color=color.red, style=plot.style_columns, title="MACD Histogram")
macd_line_plot = plot(show_macd ? macdLine : na, color=color.blue, title="MACD Line")
signal_line_plot = plot(show_macd ? signalLine : na, color=color.orange, title="Signal Line")
// 5. SMI (Stochastic Momentum Index)
show_smi = input(true, title="Show SMI")
smi_k_len = input.int(14, title="SMI K Length")
smi_d_len = input.int(3, title="SMI D Length")
smi_smooth = input.int(3, title="SMI Smooth")
smi = ta.sma(ta.stoch(close, high, low, smi_k_len), smi_smooth)
smi_signal = ta.sma(smi, smi_d_len)
plot(show_smi ? smi : na, color=color.fuchsia, title="SMI")
plot(show_smi ? smi_signal : na, color=color.teal, title="SMI Signal")
hline(-40, "SMI Oversold", color=color.red)
hline(40, "SMI Overbought", color=color.green)
// 6. Volume (أحجام التداول)
show_vol = input(true, title="Show Volume")
plot(show_vol ? volume : na, color=color.gray, style=plot.style_columns, title="Volume")
// إشارات الشراء حسب شروطك (تشبع بيعي SMI أقل من -40، الدونشيان أخضر، ستوكاستك أقل من 20، خط MACD ليس أسفل الهيستوجرام)
buy_signal = smi < -40 and donchian_trend == 1 and k < 20 and macdLine >= hist
plotshape(buy_signal, style=shape.triangleup, location=location.belowbar, color=color.green, size=size.small, title="Buy Signal")
version
=5
indicator("Multi Indicator Template - Stoch, MACD, Donchian, SMI, EMA, Volume", overlay=true)
// 1. EMA (متوسط متحرك أسي)
show_ema = input(true, title="Show EMA")
ema_length = input.int(14, title="EMA Length")
ema_val = ta.ema(close, ema_length)
plot(show_ema ? ema_val : na, color=color.blue, title="EMA")
// 2. Donchian Trend Ribbon
show_donchian = input(true, title="Show Donchian Trend Ribbon")
donchian_length = input.int(20, title="Donchian Length")
donchian_upper = ta.highest(high, donchian_length)
donchian_lower = ta.lowest(low, donchian_length)
donchian_mid = (donchian_upper + donchian_lower) / 2
donchian_trend = close > donchian_mid ? 1 : close < donchian_mid ? -1 : 0
bgcolor(show_donchian ? (donchian_trend == 1 ? color.new(color.green, 85) : donchian_trend == -1 ? color.new(color.red, 85) : na) : na, title="Donchian Trend Ribbon")
// 3. Stochastic Oscillator
show_stoch = input(true, title="Show Stochastic")
stoch_k_len = input.int(14, title="Stoch K Length")
stoch_d_len = input.int(3, title="Stoch D Length")
k = ta.stoch(close, high, low, stoch_k_len)
d = ta.sma(k, stoch_d_len)
plot(show_stoch ? k : na, color=color.purple, title="Stoch %K")
plot(show_stoch ? d : na, color=color.orange, title="Stoch %D")
hline(20, "Oversold", color=color.gray)
hline(80, "Overbought", color=color.gray)
// 4. MACD
show_macd = input(true, title="Show MACD")
[macdLine, signalLine, hist] = ta.macd(close, 12, 26, 9)
macd_hist_plot = plot(show_macd ? hist : na, color=color.red, style=plot.style_columns, title="MACD Histogram")
macd_line_plot = plot(show_macd ? macdLine : na, color=color.blue, title="MACD Line")
signal_line_plot = plot(show_macd ? signalLine : na, color=color.orange, title="Signal Line")
// 5. SMI (Stochastic Momentum Index)
show_smi = input(true, title="Show SMI")
smi_k_len = input.int(14, title="SMI K Length")
smi_d_len = input.int(3, title="SMI D Length")
smi_smooth = input.int(3, title="SMI Smooth")
smi = ta.sma(ta.stoch(close, high, low, smi_k_len), smi_smooth)
smi_signal = ta.sma(smi, smi_d_len)
plot(show_smi ? smi : na, color=color.fuchsia, title="SMI")
plot(show_smi ? smi_signal : na, color=color.teal, title="SMI Signal")
hline(-40, "SMI Oversold", color=color.red)
hline(40, "SMI Overbought", color=color.green)
// 6. Volume (أحجام التداول)
show_vol = input(true, title="Show Volume")
plot(show_vol ? volume : na, color=color.gray, style=plot.style_columns, title="Volume")
// إشارات الشراء حسب شروطك (تشبع بيعي SMI أقل من -40، الدونشيان أخضر، ستوكاستك أقل من 20، خط MACD ليس أسفل الهيستوجرام)
buy_signal = smi < -40 and donchian_trend == 1 and k < 20 and macdLine >= hist
plotshape(buy_signal, style=shape.triangleup, location=location.belowbar, color=color.green, size=size.small, title="Buy Signal")
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由且不受任何限制地使用它 — 在此處了解更多資訊。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由且不受任何限制地使用它 — 在此處了解更多資訊。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。