搜尋
產品
社群
市場
新聞
經紀商
更多
TW
立即開始
SIRI PINE SCRIPT - crossover dan barcolor untuk indicator
教育
PUBLIC BANK BHD
(
MYX:PBBANK
)
BURSATRENDBANDCHART
Essential
已更新
MYX:PBBANK
PUBLIC BANK BHD
Trend Analysis
Chart Patterns
Technical Indicators
stochrsicross
barcolor
pinescript
trendbandguide
6
0
trendanalysis
chartpattern
indicator
stochrsicross
barcolor
pinescript
trendbandguide
Permintaan dari rakan kita untuk mewarnakan candle jika syarat pada stochrsi tercapai serta membuat simple alert berdasarkan syarat tadi.
Semoga terhibur.
評論:
//@version=4
study(title="Stochastic RSI", shorttitle="Stoch RSI", format=format.price, precision=2, resolution="")
smoothK = input(3, "K", minval=1)
smoothD = input(3, "D", minval=1)
lengthRSI = input(14, "RSI Length", minval=1)
lengthStoch = input(14, "Stochastic Length", minval=1)
src = input(close, title="RSI Source")
rsi1 = rsi(src, lengthRSI)
k = sma(stoch(rsi1, rsi1, rsi1, lengthStoch), smoothK)
d = sma(k, smoothD)
plot(k, "K", color=#0094FF)
plot(d, "D", color=#FF6A00)
h0 = hline(80, "Upper Band", color=#606060)
h1 = hline(20, "Lower Band", color=#606060)
fill(h0, h1, color=#9915FF, transp=80, title="Background")
green = crossover(k,d) and k <= 20 and d <= 20
red = crossover(d,k) and k >=80 and d >= 80
barcolor (color = green ? color.green : red ? color.red : na)
alertcondition(green, title='Green bar', message = '{{tickerid}} - Crossover from below')
alertcondition(red, title='Red bar', message = '{{tickerid}} - Crossover from above')
相關想法
Alert indikator tanpa script
BURSATRENDBANDCHART
Essential
about
ADVENTA
5
Persamaan indikator yang selalu digunakan
BURSATRENDBANDCHART
Essential
about
DUFU
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在
使用條款
閱讀更多資訊。
study(title="Stochastic RSI", shorttitle="Stoch RSI", format=format.price, precision=2, resolution="")
smoothK = input(3, "K", minval=1)
smoothD = input(3, "D", minval=1)
lengthRSI = input(14, "RSI Length", minval=1)
lengthStoch = input(14, "Stochastic Length", minval=1)
src = input(close, title="RSI Source")
rsi1 = rsi(src, lengthRSI)
k = sma(stoch(rsi1, rsi1, rsi1, lengthStoch), smoothK)
d = sma(k, smoothD)
plot(k, "K", color=#0094FF)
plot(d, "D", color=#FF6A00)
h0 = hline(80, "Upper Band", color=#606060)
h1 = hline(20, "Lower Band", color=#606060)
fill(h0, h1, color=#9915FF, transp=80, title="Background")
green = crossover(k,d) and k <= 20 and d <= 20
red = crossover(d,k) and k >=80 and d >= 80
barcolor (color = green ? color.green : red ? color.red : na)
alertcondition(green, title='Green bar', message = '{{tickerid}} - Crossover from below')
alertcondition(red, title='Red bar', message = '{{tickerid}} - Crossover from above')