OPEN-SOURCE SCRIPT

king

94
//version=5
indicator("BTC_QQQ_Crown_Indicator", overlay=true)

// 1. MACD Numbers (8, 16, 11)
[m_line, s_line, hist] = ta.macd(close, 8, 16, 11)

// 2. Engulfing Candle Logic
bull = close[1] < open[1] and open < close[1] and close > open[1]
bear = close[1] > open[1] and open > close[1] and close < open[1]

// 3. Crown Signal Condition
crownBuy = bull and hist > hist[1]
crownSell = bear and hist < hist[1]

// 4. Drawing Crowns on Chart
plotshape(crownBuy, title="Buy_Crown", style=shape.labelup, location=location.belowbar, color=color.yellow, size=size.normal, text="👑\nBUY", textcolor=color.black)
plotshape(crownSell, title="Sell_Crown", style=shape.labeldown, location=location.abovebar, color=color.red, size=size.normal, text="👑\nSELL", textcolor=color.white)

免責事項

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