AkifTokuz

Midas_Channel

Update: As you can see last channel is anchored wrong and I dont know how to edit that picture:) So here is the corrected one
https://www.tradingview.com/e/PMhbcHQY/

Middle Line : Traditional MIDAS line calculated with hl2
Lower Line: MIDAS line calculated with low values
Upper Line: MIDAS line calculated with high values
開源腳本

本著真正的TradingView精神,該腳本的作者將其開源發布,以便交易者可以理解和驗證它。為作者喝彩吧!您可以免費使用它,但在出版物中重複使用此代碼受網站規則的約束。 您可以收藏它以在圖表上使用。

免責聲明

這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。

想在圖表上使用此腳本?
// Akif TOKUZ
// akifusenet@gmail.com
// MIDAS Channel

study("Midas Channel", overlay=true)

startBar=input(title="Starting Bar Number",minval=1,maxval=100000,defval=20)

start = (n==startBar-1)


v = na(volume) ? 1 : volume

cumV = cum(v)
CumPV = cum(hl2*v)
SupportCumPV = cum(low*v)
ResistanceCumPV = cum(high*v)

startV = valuewhen(start,cumV,0)
StartPV = valuewhen(start,CumPV,0)
SupportStartPV = valuewhen(start,SupportCumPV,0)
ResistanceStartPV = valuewhen(start,ResistanceCumPV,0)

Midas = (CumPV-StartPV)/(cumV-startV)
SupportMidas = (SupportCumPV-SupportStartPV)/(cumV-startV)
ResistanceMidas = (ResistanceCumPV-ResistanceStartPV)/(cumV-startV)

middle = plot(Midas, color=aqua,linewidth=2)
lower = plot(SupportMidas, color=blue,linewidth=1)
upper = plot(ResistanceMidas, color=red,linewidth=1)
fill(lower,upper,color=#1c86ee,transp=80)