liw0

Time Segmented Volume

Time Segmented Volume
an indicator I was asked to port by sunnyd76

CREDITS: quant.stackexchange....ime-segmented-volume

If you like it I would also be happy about a small donation
BTC 1GyfGTBsVHMbPovFGFeipe7b7ET1aebGx5

Questions or Comments? Just send me a PM!

Açık kaynak kodlu komut dosyası

Gerçek TradingView ruhuyla, bu betiğin yazarı, yatırımcının anlayabilmesi ve doğrulayabilmesi için onu açık kaynak olarak yayınladı. Yazarın eline sağlık! Bunu ücretsiz olarak kullanabilirsiniz, ancak bu kodun bir yayında yeniden kullanımı Kullanım Koşulları ile yönetilir. Bir grafikte kullanmak için favorilere ekleyebilirsiniz.

Feragatname

Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.

Bu komut dosyasını bir grafikte kullanmak ister misiniz?
//      Written by liw0 active on https://www.tradingview.com/u/liw0
 
//      If you decide to use my script in your published charts,
//      please keep this header as it is now and leave the name unchanged!
//      It would make me happy to see my script put to use in other charts :)
 
//      If you like it I would also be happy about a small donation
//      BTC 1GyfGTBsVHMbPovFGFeipe7b7ET1aebGx5
 
//      Questions or Comments? Just send me a PM!

//      CREDITS: http://quant.stackexchange.com/questions/2816/how-to-calculate-time-segmented-volume

study("Time Segmented Volume")

l  = input(13, title="Length")
l_ma = input(7, title="MA Length")

t = sum(close>close[1]?volume*close-close[1]:close<close[1]?(volume*-1)*close-close:0,l)
m = sma(t ,l_ma )

plot(t, color=red, style=histogram)
plot(m, color=green)