Initially the volume indicates the number of contracts that are linked in the market in a specific time frame. This indicator tries to separate the long and short volume into a candle. Once the volume of each candle is separated, the indicator is calculated based on the simple average (long length) minus the exponential average (short length).
In addition, there is a MACD calculated on volume has been added, which allows us to have confirmation that the volume is correct and not false. Beware, the MACD is not the sum total of the long and short volume !!
Remember, this is not a pure/full volume, that’s why sometimes you’ll see the volume under 0, This is accelerate VOLUME.
You’re comments are welcome.
Regards
Xusto
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 |
//Created by Xusto //v0.1 //Buy and Sell volume acelerate. This is nor a pure volume //PeriodFast --> Bar numbers used for fast period calculations (Value Recomended 4) PeriodFast = 4 //PeriodSlow --> Bar numbers used for slow period calculations (Value Recomended 10) PeriodSlow = 10 /////////////////////////////////////// /////////////////////////////////////// //Candle Sections //Full Range a = high-low //Green Candle b = open-low c = high-close //Red Candle d = high-open e = close-low /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// //Unitary volume (Buy&Sell) //Green Candle volUniBuy = volume/(a+b+c) //Red Candle volUniSell = volume/(a+d+e) /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// //Volume calculated by candle //Buy volume on green candle VolBuyGreen=a*volUniBuy //Buy volume on red candle VolBuyRed=(d+e)*volUniSell //Sell Volume on green candle VolSellGreen=(b+c)*volUniBuy //Sell Volume on red candle VolSellRed=a*volUniSell if close>=open then VolBuyGreen = VolBuyRed VolSellGreen = 0 else VolSellRed = VolSellGreen VolBuyRed = 0 endif /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// //Average AverageVolBuy1=ExponentialAverage[PeriodFast](VolBuyGreen) AverageVolSell1=ExponentialAverage[PeriodFast](VolSellRed) AverageVolBuy2=Average[PeriodSlow](VolBuyGreen) AverageVolSell2=Average[PeriodSlow](VolSellRed) AverageVolumeBuy=AverageVolBuy1-AverageVolBuy2 AverageVolumeSell=AverageVolSell1-AverageVolSell2 /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// /////////////////////////////////////// //MACD calculated over volume MMFast = exponentialAverage[4](volume) MMSlow = exponentialAverage[10](volume) MACDVolume = MMFast - MMSlow /////////////////////////////////////// /////////////////////////////////////// return AverageVolumeBuy coloured(0,255,0) style(line,2) as "Long Volume", AverageVolumeSell coloured(255,0,0) style(line,2) as "Short Volume", MACDVolume coloured(195,195,195) style(line,2) as "MACD", 0 as "Zero Line" |
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments :PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Buongiorno io non riesco a visualizzare nessun tipo di volume , mi torna sempre una linea dritta e costante, sicuramente sarà qualche impostazione da programma che non ho ben settato
Assicurati che lo strumento che stai guardando abbia dei volumi! È il caso?