Posts

Showing posts from February, 2021

Pinescript Code for Hilega Milega

Image
  Strategy and image Credit: NK@StockTalk //@version=3 // © ObserveNifty study("Hilega Milega Strategy by @ObserveNifty", overlay=true) //length_RSI = input(9) priceRSI = close rsi = rsi(priceRSI, 9) wma_rsi = wma(rsi, 21) ema_rsi = ema(rsi, 3) vwap_close = vwap(close) // Deternine if we are currently LONG isLong = false isLong := nz(isLong[1], false) // Determine if we are currently SHORT isShort = false isShort := nz(isShort[1], false) // buytrigger = not isLong and crossover(vrsi14,50) and crossover(vrsi5,70) buytrigger = not isLong and wma_rsi < ema_rsi and wma_rsi > 50 and close > vwap_close plotshape(buytrigger, title="Buy Signal Generated", text="Buy", textcolor=white, style=shape.labeldown, location=location.abovebar, color=red, transp=0, size=size.tiny) buyExit = isLong and (wma_rsi > ema_rsi or wma_rsi <= 50 or close < vwap_close) plotshape(buyExit, title="Exit Buy", text="Exit Buy", textcolor=wh...