vdubus

BIGMAC_DD_VX2

268 0 34
MACD_VX1
//Modified MACD and RSI alert
Remove from Favorite Scripts Add to Favorite Scripts
study(title="BIGMAC_DD_VX2", shorttitle="BIGMAC_DD_VX2")
source = close
fastLength = input(13, minval=1), slowLength=input(34,minval=1)
signalLength=input(5,minval=1)
fastMA = ema(source, fastLength)
slowMA = ema(source, slowLength)
macd = fastMA - slowMA
signal = sma(macd, signalLength)
hist = macd - signal
plot(hist, style=histogram, color=black, linewidth=3)
plot(macd, color=red, linewidth=1)
plot(signal, color=blue, linewidth=2)
plot(cross(signal, macd) ? signal : na, color=black, style = circles, linewidth = 4)
//============================================
//Modified MACD and RSI alert / munsifk 
fastLength2 = input(8, minval=1)
slowLength2 = input(34,minval=1)
signalLength2=input(3,minval=1)
hline(0, color=purple, linestyle=line)
fastMA2 = ema(close, fastLength2)
slowMA2 = ema(close, slowLength2)
macd2 = fastMA2 - slowMA2
signal2 = sma(macd2, signalLength2)
//------------
Length2 = input(21, minval=1)
Oversold2 = input(49, minval=1)
Overbought2 = input(51, minval=1)
xRSI = rsi(close, Length2)
pos2 = iff(xRSI > Overbought2 and signal2 < macd2, 1,
        iff(xRSI < Oversold2 and signal2 > macd2, -1, nz(pos2[1], 0))) 
plot(pos2, title="pos", style=area, color=red, transp=80)
//--------------------------------------------------------//
Ideas Scripts Chart
United States
United Kingdom
India
España
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Billing Sign Out