OPEN-SOURCE SCRIPT
CME Crude Oil 15-Min Multi-Unified Entry Zones (Dot Signals)

//version=6
indicator("CME Crude Oil 15-Min Multi-Unified Entry Zones (Dot Signals)", overlay=true)
// --- Input Parameters ---
emaLength = input.int(11, title="EMA Length", minval=1)
// Ichimoku Cloud Inputs (Adjusted for higher sensitivity)
conversionLineLength = input.int(7, title="Ichimoku Conversion Line Length (Sensitive)", minval=1)
baseLineLength = input.int(20, title="Ichimoku Base Line Length (Sensitive)", minval=1)
laggingSpanLength = input.int(40, title="Ichimoku Lagging Span Length (Sensitive)", minval=1)
displacement = input.int(26, title="Ichimoku Displacement", minval=1)
// MACD Inputs (Adjusted for higher sensitivity)
fastLength = input.int(9, title="MACD Fast Length (Sensitive)", minval=1)
slowLength = input.int(21, title="MACD Slow Length (Sensitive)", minval=1)
signalLength = input.int(6, title="MACD Signal Length (Sensitive)", minval=1)
// RSI Inputs
rsiLength = input.int(8, title="RSI Length", minval=1)
rsiOverbought = input.int(70, title="RSI Overbought Level", minval=50, maxval=90)
rsiOversold = input.int(30, title="RSI Oversold Level", minval=10, maxval=50)
// ADX Inputs
adxLength = input.int(14, title="ADX Length", minval=1)
adxTrendStrengthThreshold = input.int(20, title="ADX Trend Strength Threshold", minval=10, maxval=50)
// Weak Entry Threshold (50 ticks for Crude Oil, where 1 tick = $0.01)
// 50 ticks = $0.50
weakEntryTickThreshold = input.float(0.50, title="Weak Entry Threshold (in $)", minval=0.01)
// --- Indicator Calculations ---
// 1. EMA 11
ema11 = ta.ema(close, emaLength)
// 2. Ichimoku Cloud
donchian(len) => math.avg(ta.lowest(len), ta.highest(len))
tenkanSen = donchian(conversionLineLength)
kijunSen = donchian(baseLineLength)
senkouSpanA = math.avg(tenkanSen, kijunSen)
senkouSpanB = donchian(laggingSpanLength)
// Shifted for plotting (future projection)
senkouSpanA_plot = senkouSpanA[displacement - 1]
senkouSpanB_plot = senkouSpanB[displacement - 1]
// Chikou Span (lagging span, plotted 26 periods back)
chikouSpan = close[displacement]
// 3. MACD
[macdLine, signalLine, hist] = ta.macd(close, fastLength, slowLength, signalLength)
// 4. RSI
rsi = ta.rsi(close, rsiLength)
// 5. ADX
[diPlus, diMinus, adx] = ta.dmi(adxLength, adxLength)
// --- Price Volume Pattern Logic ---
// Simplified volume confirmation:
isVolumeIncreasing = volume > volume[1]
isVolumeDecreasing = volume < volume[1]
isPriceUp = close > close[1]
isPriceDown = close < close[1]
bullishVolumeConfirmation = (isPriceUp and isVolumeIncreasing) or (isPriceDown and isVolumeDecreasing)
bearishVolumeConfirmation = (isPriceDown and isVolumeIncreasing) or (isPriceUp and isVolumeDecreasing)
// --- Daily Pivot Point Calculation (Critical Support/Resistance) ---
// Request daily High, Low, Close for pivot calculation
[dailyHigh, dailyLow, dailyClose] = request.security(syminfo.tickerid, "D", [high[1], low[1], close[1]])
// Classic Pivot Point Formula
dailyPP = (dailyHigh + dailyLow + dailyClose) / 3
dailyR1 = (2 * dailyPP) - dailyLow
dailyS1 = (2 * dailyPP) - dailyHigh
dailyR2 = dailyPP + (dailyHigh - dailyLow)
dailyS2 = dailyPP - (dailyHigh - dailyLow)
// --- Crosses and States for Unified Entry 1 (EMA & MACD) ---
// Moved ta.cross() calls outside of conditional blocks for consistent calculation.
emaGoldenCrossCondition = ta.cross(close, ema11)
emaDeathCrossCondition = ta.cross(ema11, close)
macdGoldenCrossCondition = ta.cross(macdLine, signalLine)
macdDeathCrossCondition = ta.cross(signalLine, macdLine)
emaIsBullish = close > ema11
emaIsBearish = close < ema11
macdIsBullishStrong = macdLine > signalLine and macdLine > 0
macdIsBearishStrong = macdLine < signalLine and macdLine < 0
// --- Unified Entry 1 Logic (EMA & MACD) ---
unifiedLongEntry1 = false
unifiedShortEntry1 = false
if (emaGoldenCrossCondition and macdIsBullishStrong[1])
unifiedLongEntry1 := true
else if (macdGoldenCrossCondition and emaIsBullish[1])
unifiedLongEntry1 := true
if (emaDeathCrossCondition and macdIsBearishStrong[1])
unifiedShortEntry1 := true
else if (macdDeathCrossCondition and emaIsBearish[1])
unifiedShortEntry1 := true
// --- Unified Entry 2 Logic (Ichimoku & EMA/Volume) ---
unifiedLongEntry2 = false
unifiedShortEntry2 = false
ichimokuCloudBullish = close > senkouSpanA_plot and close > senkouSpanB_plot and
senkouSpanA_plot > senkouSpanB_plot and
tenkanSen > kijunSen and
chikouSpan > close[displacement + 26]
ichimokuCloudBearish = close < senkouSpanA_plot and close < senkouSpanB_plot and
senkouSpanB_plot > senkouSpanA_plot and
tenkanSen < kijunSen and
chikouSpan < close[displacement + 26]
// Moved ta.cross() calls outside of conditional blocks for consistent calculation.
ichimokuBullishTriggerCondition = ta.cross(tenkanSen, kijunSen)
ichimokuBearishTriggerCondition = ta.cross(kijunSen, tenkanSen)
priceCrossAboveSenkouA = ta.cross(close, senkouSpanA_plot)
priceCrossBelowSenkouA = ta.cross(senkouSpanA_plot, close)
if (ichimokuBullishTriggerCondition or (priceCrossAboveSenkouA and close > senkouSpanB_plot)) and
emaIsBullish and
bullishVolumeConfirmation
unifiedLongEntry2 := true
if (ichimokuBearishTriggerCondition or (priceCrossBelowSenkouA and close < senkouSpanB_plot)) and
emaIsBearish and
bearishVolumeConfirmation
unifiedShortEntry2 := true
// --- Weak Entry Logic ---
weakLongEntry = false
weakShortEntry = false
// Function to check for weak long entry
// Checks if the distance to the nearest resistance (R1 or R2) is less than the threshold
f_isWeakLongEntry(currentPrice) =>
bool isWeak = false
// Check R1 if it's above current price and within threshold
if dailyR1 > currentPrice and (dailyR1 - currentPrice < weakEntryTickThreshold)
isWeak := true
// Check R2 if it's above current price and within threshold (only if not already weak by R1)
else if dailyR2 > currentPrice and (dailyR2 - currentPrice < weakEntryTickThreshold)
isWeak := true
isWeak
// Function to check for weak short entry
// Checks if the distance to the nearest support (S1 or S2) is less than the threshold
f_isWeakShortEntry(currentPrice) =>
bool isWeak = false
// Check S1 if it's below current price and within threshold
if dailyS1 < currentPrice and (currentPrice - dailyS1 < weakEntryTickThreshold)
isWeak := true
// Check S2 if it's below current price and within threshold (only if not already weak by S1)
else if dailyS2 < currentPrice and (currentPrice - dailyS2 < weakEntryTickThreshold)
isWeak := true
isWeak
// Apply weak entry check to Unified Entry 1
if unifiedLongEntry1 and f_isWeakLongEntry(close)
weakLongEntry := true
if unifiedShortEntry1 and f_isWeakShortEntry(close)
weakShortEntry := true
// Apply weak entry check to Unified Entry 2
if unifiedLongEntry2 and f_isWeakLongEntry(close)
weakLongEntry := true
if unifiedShortEntry2 and f_isWeakShortEntry(close)
weakShortEntry := true
// --- Enhanced Entry Conditions with RSI and ADX ---
// Removed candlestick pattern requirement.
// Only consider an entry if RSI is not overbought/oversold AND ADX indicates trend strength.
// Enhanced Long Entry Condition
enhancedLongEntry = (unifiedLongEntry1 or unifiedLongEntry2) and
(rsi < rsiOverbought) and // RSI not overbought
(adx > adxTrendStrengthThreshold) // ADX shows trend strength
// Enhanced Short Entry Condition
enhancedShortEntry = (unifiedShortEntry1 or unifiedShortEntry2) and
(rsi > rsiOversold) and // RSI not oversold
(adx > adxTrendStrengthThreshold) // ADX shows trend strength
// --- Define colors as variables for clarity and to potentially resolve parsing issues ---
// Changed named color constants to hexadecimal values
var color strongBuyDotColor = #FFD700 // Gold
var color weakBuyDotColor = #008000 // Green
var color strongSellDotColor = #FFFFFF // White
var color weakSellDotColor = #FF0000 // Red
// --- Plotting Entry Dots on Candlesticks ---
// Define conditions for plotting only on the *first* occurrence of a signal
isNewStrongBuy = enhancedLongEntry and not weakLongEntry and not (enhancedLongEntry[1] and not weakLongEntry[1])
isNewWeakBuy = enhancedLongEntry and weakLongEntry and not (enhancedLongEntry[1] and weakLongEntry[1])
isNewStrongSell = enhancedShortEntry and not weakShortEntry and not (enhancedShortEntry[1] and not weakShortEntry[1])
isNewWeakSell = enhancedShortEntry and weakShortEntry and not (enhancedShortEntry[1] and weakShortEntry[1])
// Helper functions to check candlestick type
isCurrentCandleBullish = close > open
isCurrentCandleBearish = close < open
// Strong Buy: Gold dot (only on bullish candles)
plotshape(isNewStrongBuy and isCurrentCandleBullish ? close : na, title="Strong B", location=location.absolute, color=strongBuyDotColor, style=shape.circle, size=size.tiny)
// Weak Buy: Solid Green dot (no candlestick filter for weak buys)
// Changed text to "" and style to shape.triangleup for symbol only
plotshape(isNewWeakBuy ? close : na, title="Weak B", location=location.absolute, color=weakBuyDotColor, style=shape.triangleup, size=size.tiny)
// Strong Sell: White dot (only on bearish candles)
plotshape(isNewStrongSell and isCurrentCandleBearish ? close : na, title="Strong S", location=location.absolute, color=strongSellDotColor, style=shape.circle, size=size.tiny)
// Weak Sell: Red dot (no candlestick filter for weak sells)
// Changed text to "" and style to shape.triangledown for symbol only
plotshape(isNewWeakSell ? close : na, title="Weak S", location=location.absolute, color=weakSellDotColor, style=shape.triangledown, size=size.tiny)
// --- Plotting Indicators (Optional, for visual confirmation) ---
// All indicator plots have been removed as requested.
// plot(ema11, title="EMA 11", color=emaColor)
// plot(tenkanSen, title="Tenkan-Sen", color=tenkanColor)
// plot(kijunSen, title="Kijun-Sen", color=kijunColor)
// plot(senkouSpanA_plot, title="Senkou Span A", color=senkouAColor, offset=displacement)
// plot(senkouSpanB_plot, title="Senkou Span B", color=senkouBColor, offset=displacement)
// fill(plot(senkouSpanA_plot, offset=displacement), plot(senkouSpanB_plot, offset=displacement), color=cloudFillBullishColor, title="Cloud Fill Bullish")
// fill(plot(senkouSpanA_plot, offset=displacement), plot(senkouSpanB_plot, offset=displacement), color=cloudFillBearishColor, title="Cloud Fill Bearish")
// plot(chikouSpan, title="Chikou Span", color=chikouColor, offset=-displacement)
// plot(macdLine, title="MACD Line", color=macdLineColor, display=display.pane)
// plot(signalLine, title="Signal Line", color=signalLineColor, display=display.pane)
// plot(hist, title="Histogram", color=hist >= 0 ? histGreenColor : histRedColor, style=plot.style_columns, display=display.pane)
// plot(rsi, title="RSI", color=rsiPlotColor, display=display.pane)
// hline(rsiOverbought, "RSI Overbought", color=rsiHlineRedColor, linestyle=hline.style_dashed, display=display.all)
// hline(rsiOversold, "RSI Oversold", color=rsiHlineGreenColor, linestyle=hline.style_dashed, display=display.all)
// plot(adx, title="ADX", color=adxPlotColor, display=display.pane)
// hline(adxTrendStrengthThreshold, "ADX Threshold", color=adxHlineColor, linestyle=hline.style_dashed, display=display.all)
// plot(diPlus, title="+DI", color=diPlusColor, display=display.pane)
// plot(diMinus, title="-DI", color=diMinusColor, display=display.pane)
// plot(dailyPP, title="Daily PP", color=dailyPPColor, style=plot.style_line, linewidth=1)
// plot(dailyR1, title="Daily R1", color=dailyRColor, style=plot.style_line, linewidth=1)
// plot(dailyR2, title="Daily R2", color=dailyRColor, style=plot.style_line, linewidth=1)
// plot(dailyS1, title="Daily S1", color=dailySColor, style=plot.style_line, linewidth=1)
// plot(dailyS2, title="Daily S2", color=dailySColor, style=plot.style_line, linewidth=1)
// --- Alerts (Optional) ---
alertcondition(enhancedLongEntry and not weakLongEntry, title="Strong Buy Alert", message="CME Crude Oil: Strong Buy Entry!")
alertcondition(enhancedLongEntry and weakLongEntry, title="Weak Buy Alert", message="CME Crude Oil: Weak Buy Entry Detected!")
alertcondition(enhancedShortEntry and not weakShortEntry, title="Strong Sell Alert", message="CME Crude Oil: Strong Sell Entry!")
alertcondition(enhancedShortEntry and weakShortEntry, title="Weak Sell Alert", message="CME Crude Oil: Weak Sell Entry Detected!")
indicator("CME Crude Oil 15-Min Multi-Unified Entry Zones (Dot Signals)", overlay=true)
// --- Input Parameters ---
emaLength = input.int(11, title="EMA Length", minval=1)
// Ichimoku Cloud Inputs (Adjusted for higher sensitivity)
conversionLineLength = input.int(7, title="Ichimoku Conversion Line Length (Sensitive)", minval=1)
baseLineLength = input.int(20, title="Ichimoku Base Line Length (Sensitive)", minval=1)
laggingSpanLength = input.int(40, title="Ichimoku Lagging Span Length (Sensitive)", minval=1)
displacement = input.int(26, title="Ichimoku Displacement", minval=1)
// MACD Inputs (Adjusted for higher sensitivity)
fastLength = input.int(9, title="MACD Fast Length (Sensitive)", minval=1)
slowLength = input.int(21, title="MACD Slow Length (Sensitive)", minval=1)
signalLength = input.int(6, title="MACD Signal Length (Sensitive)", minval=1)
// RSI Inputs
rsiLength = input.int(8, title="RSI Length", minval=1)
rsiOverbought = input.int(70, title="RSI Overbought Level", minval=50, maxval=90)
rsiOversold = input.int(30, title="RSI Oversold Level", minval=10, maxval=50)
// ADX Inputs
adxLength = input.int(14, title="ADX Length", minval=1)
adxTrendStrengthThreshold = input.int(20, title="ADX Trend Strength Threshold", minval=10, maxval=50)
// Weak Entry Threshold (50 ticks for Crude Oil, where 1 tick = $0.01)
// 50 ticks = $0.50
weakEntryTickThreshold = input.float(0.50, title="Weak Entry Threshold (in $)", minval=0.01)
// --- Indicator Calculations ---
// 1. EMA 11
ema11 = ta.ema(close, emaLength)
// 2. Ichimoku Cloud
donchian(len) => math.avg(ta.lowest(len), ta.highest(len))
tenkanSen = donchian(conversionLineLength)
kijunSen = donchian(baseLineLength)
senkouSpanA = math.avg(tenkanSen, kijunSen)
senkouSpanB = donchian(laggingSpanLength)
// Shifted for plotting (future projection)
senkouSpanA_plot = senkouSpanA[displacement - 1]
senkouSpanB_plot = senkouSpanB[displacement - 1]
// Chikou Span (lagging span, plotted 26 periods back)
chikouSpan = close[displacement]
// 3. MACD
[macdLine, signalLine, hist] = ta.macd(close, fastLength, slowLength, signalLength)
// 4. RSI
rsi = ta.rsi(close, rsiLength)
// 5. ADX
[diPlus, diMinus, adx] = ta.dmi(adxLength, adxLength)
// --- Price Volume Pattern Logic ---
// Simplified volume confirmation:
isVolumeIncreasing = volume > volume[1]
isVolumeDecreasing = volume < volume[1]
isPriceUp = close > close[1]
isPriceDown = close < close[1]
bullishVolumeConfirmation = (isPriceUp and isVolumeIncreasing) or (isPriceDown and isVolumeDecreasing)
bearishVolumeConfirmation = (isPriceDown and isVolumeIncreasing) or (isPriceUp and isVolumeDecreasing)
// --- Daily Pivot Point Calculation (Critical Support/Resistance) ---
// Request daily High, Low, Close for pivot calculation
[dailyHigh, dailyLow, dailyClose] = request.security(syminfo.tickerid, "D", [high[1], low[1], close[1]])
// Classic Pivot Point Formula
dailyPP = (dailyHigh + dailyLow + dailyClose) / 3
dailyR1 = (2 * dailyPP) - dailyLow
dailyS1 = (2 * dailyPP) - dailyHigh
dailyR2 = dailyPP + (dailyHigh - dailyLow)
dailyS2 = dailyPP - (dailyHigh - dailyLow)
// --- Crosses and States for Unified Entry 1 (EMA & MACD) ---
// Moved ta.cross() calls outside of conditional blocks for consistent calculation.
emaGoldenCrossCondition = ta.cross(close, ema11)
emaDeathCrossCondition = ta.cross(ema11, close)
macdGoldenCrossCondition = ta.cross(macdLine, signalLine)
macdDeathCrossCondition = ta.cross(signalLine, macdLine)
emaIsBullish = close > ema11
emaIsBearish = close < ema11
macdIsBullishStrong = macdLine > signalLine and macdLine > 0
macdIsBearishStrong = macdLine < signalLine and macdLine < 0
// --- Unified Entry 1 Logic (EMA & MACD) ---
unifiedLongEntry1 = false
unifiedShortEntry1 = false
if (emaGoldenCrossCondition and macdIsBullishStrong[1])
unifiedLongEntry1 := true
else if (macdGoldenCrossCondition and emaIsBullish[1])
unifiedLongEntry1 := true
if (emaDeathCrossCondition and macdIsBearishStrong[1])
unifiedShortEntry1 := true
else if (macdDeathCrossCondition and emaIsBearish[1])
unifiedShortEntry1 := true
// --- Unified Entry 2 Logic (Ichimoku & EMA/Volume) ---
unifiedLongEntry2 = false
unifiedShortEntry2 = false
ichimokuCloudBullish = close > senkouSpanA_plot and close > senkouSpanB_plot and
senkouSpanA_plot > senkouSpanB_plot and
tenkanSen > kijunSen and
chikouSpan > close[displacement + 26]
ichimokuCloudBearish = close < senkouSpanA_plot and close < senkouSpanB_plot and
senkouSpanB_plot > senkouSpanA_plot and
tenkanSen < kijunSen and
chikouSpan < close[displacement + 26]
// Moved ta.cross() calls outside of conditional blocks for consistent calculation.
ichimokuBullishTriggerCondition = ta.cross(tenkanSen, kijunSen)
ichimokuBearishTriggerCondition = ta.cross(kijunSen, tenkanSen)
priceCrossAboveSenkouA = ta.cross(close, senkouSpanA_plot)
priceCrossBelowSenkouA = ta.cross(senkouSpanA_plot, close)
if (ichimokuBullishTriggerCondition or (priceCrossAboveSenkouA and close > senkouSpanB_plot)) and
emaIsBullish and
bullishVolumeConfirmation
unifiedLongEntry2 := true
if (ichimokuBearishTriggerCondition or (priceCrossBelowSenkouA and close < senkouSpanB_plot)) and
emaIsBearish and
bearishVolumeConfirmation
unifiedShortEntry2 := true
// --- Weak Entry Logic ---
weakLongEntry = false
weakShortEntry = false
// Function to check for weak long entry
// Checks if the distance to the nearest resistance (R1 or R2) is less than the threshold
f_isWeakLongEntry(currentPrice) =>
bool isWeak = false
// Check R1 if it's above current price and within threshold
if dailyR1 > currentPrice and (dailyR1 - currentPrice < weakEntryTickThreshold)
isWeak := true
// Check R2 if it's above current price and within threshold (only if not already weak by R1)
else if dailyR2 > currentPrice and (dailyR2 - currentPrice < weakEntryTickThreshold)
isWeak := true
isWeak
// Function to check for weak short entry
// Checks if the distance to the nearest support (S1 or S2) is less than the threshold
f_isWeakShortEntry(currentPrice) =>
bool isWeak = false
// Check S1 if it's below current price and within threshold
if dailyS1 < currentPrice and (currentPrice - dailyS1 < weakEntryTickThreshold)
isWeak := true
// Check S2 if it's below current price and within threshold (only if not already weak by S1)
else if dailyS2 < currentPrice and (currentPrice - dailyS2 < weakEntryTickThreshold)
isWeak := true
isWeak
// Apply weak entry check to Unified Entry 1
if unifiedLongEntry1 and f_isWeakLongEntry(close)
weakLongEntry := true
if unifiedShortEntry1 and f_isWeakShortEntry(close)
weakShortEntry := true
// Apply weak entry check to Unified Entry 2
if unifiedLongEntry2 and f_isWeakLongEntry(close)
weakLongEntry := true
if unifiedShortEntry2 and f_isWeakShortEntry(close)
weakShortEntry := true
// --- Enhanced Entry Conditions with RSI and ADX ---
// Removed candlestick pattern requirement.
// Only consider an entry if RSI is not overbought/oversold AND ADX indicates trend strength.
// Enhanced Long Entry Condition
enhancedLongEntry = (unifiedLongEntry1 or unifiedLongEntry2) and
(rsi < rsiOverbought) and // RSI not overbought
(adx > adxTrendStrengthThreshold) // ADX shows trend strength
// Enhanced Short Entry Condition
enhancedShortEntry = (unifiedShortEntry1 or unifiedShortEntry2) and
(rsi > rsiOversold) and // RSI not oversold
(adx > adxTrendStrengthThreshold) // ADX shows trend strength
// --- Define colors as variables for clarity and to potentially resolve parsing issues ---
// Changed named color constants to hexadecimal values
var color strongBuyDotColor = #FFD700 // Gold
var color weakBuyDotColor = #008000 // Green
var color strongSellDotColor = #FFFFFF // White
var color weakSellDotColor = #FF0000 // Red
// --- Plotting Entry Dots on Candlesticks ---
// Define conditions for plotting only on the *first* occurrence of a signal
isNewStrongBuy = enhancedLongEntry and not weakLongEntry and not (enhancedLongEntry[1] and not weakLongEntry[1])
isNewWeakBuy = enhancedLongEntry and weakLongEntry and not (enhancedLongEntry[1] and weakLongEntry[1])
isNewStrongSell = enhancedShortEntry and not weakShortEntry and not (enhancedShortEntry[1] and not weakShortEntry[1])
isNewWeakSell = enhancedShortEntry and weakShortEntry and not (enhancedShortEntry[1] and weakShortEntry[1])
// Helper functions to check candlestick type
isCurrentCandleBullish = close > open
isCurrentCandleBearish = close < open
// Strong Buy: Gold dot (only on bullish candles)
plotshape(isNewStrongBuy and isCurrentCandleBullish ? close : na, title="Strong B", location=location.absolute, color=strongBuyDotColor, style=shape.circle, size=size.tiny)
// Weak Buy: Solid Green dot (no candlestick filter for weak buys)
// Changed text to "" and style to shape.triangleup for symbol only
plotshape(isNewWeakBuy ? close : na, title="Weak B", location=location.absolute, color=weakBuyDotColor, style=shape.triangleup, size=size.tiny)
// Strong Sell: White dot (only on bearish candles)
plotshape(isNewStrongSell and isCurrentCandleBearish ? close : na, title="Strong S", location=location.absolute, color=strongSellDotColor, style=shape.circle, size=size.tiny)
// Weak Sell: Red dot (no candlestick filter for weak sells)
// Changed text to "" and style to shape.triangledown for symbol only
plotshape(isNewWeakSell ? close : na, title="Weak S", location=location.absolute, color=weakSellDotColor, style=shape.triangledown, size=size.tiny)
// --- Plotting Indicators (Optional, for visual confirmation) ---
// All indicator plots have been removed as requested.
// plot(ema11, title="EMA 11", color=emaColor)
// plot(tenkanSen, title="Tenkan-Sen", color=tenkanColor)
// plot(kijunSen, title="Kijun-Sen", color=kijunColor)
// plot(senkouSpanA_plot, title="Senkou Span A", color=senkouAColor, offset=displacement)
// plot(senkouSpanB_plot, title="Senkou Span B", color=senkouBColor, offset=displacement)
// fill(plot(senkouSpanA_plot, offset=displacement), plot(senkouSpanB_plot, offset=displacement), color=cloudFillBullishColor, title="Cloud Fill Bullish")
// fill(plot(senkouSpanA_plot, offset=displacement), plot(senkouSpanB_plot, offset=displacement), color=cloudFillBearishColor, title="Cloud Fill Bearish")
// plot(chikouSpan, title="Chikou Span", color=chikouColor, offset=-displacement)
// plot(macdLine, title="MACD Line", color=macdLineColor, display=display.pane)
// plot(signalLine, title="Signal Line", color=signalLineColor, display=display.pane)
// plot(hist, title="Histogram", color=hist >= 0 ? histGreenColor : histRedColor, style=plot.style_columns, display=display.pane)
// plot(rsi, title="RSI", color=rsiPlotColor, display=display.pane)
// hline(rsiOverbought, "RSI Overbought", color=rsiHlineRedColor, linestyle=hline.style_dashed, display=display.all)
// hline(rsiOversold, "RSI Oversold", color=rsiHlineGreenColor, linestyle=hline.style_dashed, display=display.all)
// plot(adx, title="ADX", color=adxPlotColor, display=display.pane)
// hline(adxTrendStrengthThreshold, "ADX Threshold", color=adxHlineColor, linestyle=hline.style_dashed, display=display.all)
// plot(diPlus, title="+DI", color=diPlusColor, display=display.pane)
// plot(diMinus, title="-DI", color=diMinusColor, display=display.pane)
// plot(dailyPP, title="Daily PP", color=dailyPPColor, style=plot.style_line, linewidth=1)
// plot(dailyR1, title="Daily R1", color=dailyRColor, style=plot.style_line, linewidth=1)
// plot(dailyR2, title="Daily R2", color=dailyRColor, style=plot.style_line, linewidth=1)
// plot(dailyS1, title="Daily S1", color=dailySColor, style=plot.style_line, linewidth=1)
// plot(dailyS2, title="Daily S2", color=dailySColor, style=plot.style_line, linewidth=1)
// --- Alerts (Optional) ---
alertcondition(enhancedLongEntry and not weakLongEntry, title="Strong Buy Alert", message="CME Crude Oil: Strong Buy Entry!")
alertcondition(enhancedLongEntry and weakLongEntry, title="Weak Buy Alert", message="CME Crude Oil: Weak Buy Entry Detected!")
alertcondition(enhancedShortEntry and not weakShortEntry, title="Strong Sell Alert", message="CME Crude Oil: Strong Sell Entry!")
alertcondition(enhancedShortEntry and weakShortEntry, title="Weak Sell Alert", message="CME Crude Oil: Weak Sell Entry Detected!")
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.