Hilega milega indicator

Pls bring this indicator, it will super helpfull for overall

its created by NK sir

//@version=5

indicator(title="Hilega Milega", shorttitle="HM", overlay=false, format=format.price, precision=2)

// ==========================================

// --- INPUTS ---

// ==========================================

len = input.int(9, minval=1, title="RSI Length")

src = input.source(close, "Source")

wma_len = input.int(21, minval=1, title="WMA Length")

ema_len = input.int(3, minval=1, title="EMA Length")

show_80 = input.bool(true, "Show Levels?", group="Levels")

level_80 = input.int(80, "Upper Level", group="Levels")

level_20 = input.int(20, "Lower Level", group="Levels")

level_50 = 50

// ==========================================

// --- CALCULATIONS ---

// ==========================================

_rsi = ta.rsi(src, len)

wma_val = ta.wma(_rsi, wma_len)

ema_val = ta.ema(_rsi, ema_len)

// ==========================================

// --- PLOTTING (OSCILLATOR) ---

// ==========================================

h_50 = plot(level_50, color=color.new(color.gray, 50), title="Mid Line 50")

hline(show_80 ? level_80 : na, color=color.new(color.red, 30), linestyle=hline.style_dashed)

hline(show_80 ? level_20 : na, color=color.new(color.green, 30), linestyle=hline.style_dashed)

p_rsi = plot(_rsi, color=color.black, linewidth=2, title="RSI")

p_wma = plot(wma_val, color=color.red, linewidth=2, title="Strength-WMA")

p_ema = plot(ema_val, color=color.green, linewidth=2, title="Price-EMA")

// Fill color changes to green if the EMA is above 50, and blue if below 50

fill(p_ema, p_wma, color = ema_val >= 50 ? color.new(color.green, 85) : color.new(color.blue, 85), title="Trend Fill")

3
2 replies