Multiple VWAPAn intraday indicator which plots the 3 different VWAP.
1. D-VWAP shows VWAP from the first candle of the day
2. W-VWAP shows VWAP from the first candle of the week
3. M-VWAP shows VWAP from the first candle of the month
Volumeweighted
VMACDIntended to be used in exactly the same way as the built-in MACD, but uses volume-weighted moving averages instead. This gives it a tiny edge for spotting high volume breakouts.
Windowed Volume Weighted Moving AverageIntroduction
The concept of windowing was briefly introduced in the Blackman filter post, however windowing is more than just some window functions, and isn't exclusively used in filter design.
Today we will use windowing with the volume weighted moving average, a moving average that weight the price with volume in order to be more reactive when volume is high, that is the moving average is more reactive when the market is more active. The use of windowing in the vwma allow to enhance its performance in the frequency domain which result in a smoother output.
Note that i made a similar indicator long ago, but at that time I was not great at all with math and pinescript in general and the indicator was therefore wrong, i want to remind to the community that i'am not a professional, only an enthusiast, I never claimed to be a master coder and i'am totally open to receive criticism, if I sounded like bragging in the past I apologize, at 20 years old it is still easy to act like a kid, the information contained in my posts is only shared in order to help others but also myself, since sharing is also a way to learn more effectively. That said lets go with the indicator.
Windowing
Windowing consist on applying a window function to a signal, by applying i mostly talk about multiplying, this process is mostly used with windowed sinc filters in order to reduce ripples in the pass/stop band, but can be used with any kind of filters in order to have better frequency domain performance, the only thing we need to do is to multiply the filter weights by a window function.
In order to understand windowing it is useful to visualize this process and understand spectral leakage. Remember that we can describe a signal as the sum of sine/cosine waves of different frequencies, amplitude and phase, leakage is an effect that appear with signals having discontinuities, that is when a signal non periodic.
This figure show a non periodic sine wave of frequency 0.1, a non periodic signal will have is last sample value different from its first sample value, if we where to do its fourier transform we wouldn't end up with a single bin at 0.1 but with more bins, this is spectral leakage, the discontinuities in the signal create additional frequency components. In order to reduce leakage we must make the signal approximately periodic, this is done by making use of window functions.
A window function is symmetric and relatively smooth, all we have to do is to multiply our first non periodic signal with the window function.
We end up with the following windowed signal :
The signal is approximately periodic and leakage has been reduced. Now that we have seen that, it might be useful to see why it is useful in filters.
Remember that the Fourier transform of the filter weights gives us its frequency response, if our weights introduce leakage we end up with ripples, so windowing the filter weights might help reduce the ripples in the frequency response, which result in a smoother filter output.
Volume Weighted Moving Average
A volume weighted moving average is a FIR filter who use volume as filter kernel, therefore the frequency response of this filter always change, it is therefore not wrong to qualify the vwma as an adaptive moving average. Higher volume mean higher weighting of the current closing price value, which therefore produce a more reactive output.
However the smoothness of the moving average is relatively poor.
Windowed Volume Weighted Moving Average
The proposed moving average has a length setting who control the moving average period, and various options that we will describe below. The first option is the type of window, there are many windows, certains more complex than others, here 3 windows are proposed, the famous Blackman window, the Bartlett, and finally the Hanning window, they provide each different level of smoothness. lets compare our moving average with period 100 with a vwma of the same period.
Our moving average in red, and the vwma in blue. As you can see the results are smoother.
The power parameter is used in order to give an even higher weighting to closing prices with high volume, this create a more boxy output. Below is a comparison with a vwma in blue and a powered vwma in red with power = 2 without windowing :
We can then apply a window, here i will choose the Blackman window :
Conclusion
A new moving average based on windowed volume weighting has been proposed. The result are smoother which might therefore reduce whipsaw trades. I wish i could have explained things better, unfortunately windowing isn't something i use much, i wanted to post this moving average earlier this year.
I will be off in France for 1 week, my flight is tomorrow in the morning, therefore i don't think i'll have the possibility to make other posts this year. I want to profit from this occasion to review my year in tradingview.
Many indicators have been posted, some being extremely bad and others really interesting, this year introduced my attempts on estimating the lsma efficiently, the linear channels, an attempt on making lines and remain the first indicator from the v4 i posted if i'am right. Then came the efficient auto-line, who gained some popularity quite fast. Then finally the %G oscillator and the recursive bands where posted, and remain some of the favorites indicators i made. I also wanted to leave this year due to studies, that i totally abandoned, i'am thankful that i chosen to stay.
I also want to express my apologies to any member that i could have offended, i think that i'am not a mean person but i certainly not contest the fact that i'am clumsy, even in my work, however my clumsiness is far greater when it comes to interact with other peoples or a group of peoples, i don't want to hurt anyone, if i made anything that made you feel bad then i'am sincerely sorry, and hope we can start this new year from 0.
Finally i thank the tradingview community for their interest and curiosity, i thank all the great coders who work on making pinescript a better scripting language, i also thank the tradingview staff for their work this year. I wish you all a merry christmas, and an happy new year.
Thanks for reading.
Combo Strategy 123 Reversal & EMA & Volume Weighting This is combo strategies for get a cumulative signal.
First strategy
This System was created from the Book "How I Tripled My Money In The
Futures Market" by Ulf Jensen, Page 183. This is reverse type of strategies.
The strategy buys at market, if close price is higher than the previous close
during 2 days and the meaning of 9-days Stochastic Slow Oscillator is lower than 50.
The strategy sells at market, if close price is lower than the previous close price
during 2 days and the meaning of 9-days Stochastic Fast Oscillator is higher than 50.
Second strategy
The related article is copyrighted material from Stocks & Commodities 2009 Oct
WARNING:
- For purpose educate only
- This script to change bars colors.
Volume Weighted Historical Volatility RankExperiment in adding volume weighting to the calculation in determining HV.
See here for HV explanation : www.investopedia.com
--------------------------------------
If you find it useful please consider a tip/donation :
BTC - 3BMEXEDyWJ58eXUEALYPadbn1wwWKmf6sA
--------------------------------------
VWMA Trend FilterHere's a simple tool for determining long term trend direction using two Volume Weighted Moving Averages (VWMA). The VWMA's emphasis on volume often makes it a better measurement for trend direction than the more popular Exponential Moving Average (EMA).
Trend direction is determined by comparing a fast and slow VWMA. The default length for the fast VWMA is 50 periods, while the slow uses a default length of 200. Both of these lengths can be modified in the input options menu. The default source for the VWMA's is HLC3((high + low + close) / 3).
If the fast VWMA is greater than the slow VWMA, then the trend is bullish and the background color is green. If the fast VWMA is less than the slow VWMA, then it is bearish and the background color is red.
We included an option to change the candle color based on whether the VWMA's indicate a bullish or bearish trend as well.
Overall, this is one of those utility tools that we like to use as an overlay over the main price chart and in conjunction with other signal generating indicators. Its purpose isn't to generate buy and sell signals, but it works well as a visual confirmation tool to help traders gauge trend direction.
Volume Weighted Bollinger (Final, cleaned up visuals)Volume-weighted bollinger (normal stats application of weighting mean) with cleaned up visualization. Shaded area represents1sd-2sd move size for trailing 20 period average on timeframe for individual candles.
VWMA/SMA Breakout and Divergence DetectorThis indicator compares four different values :
-Fast Simple Moving Average(SMA)
-Fast Volume Weighted Moving Average(VWMA)
-Slow SMA
-Slow VWMA
Comparing SMA's and VWMA's of the same length is a common trading tactic. Since volume is not taken into consideration when calculating Simple Moving Averages, we can gain valuable insights from the difference between the two lines.
Since volume should be increasing along with an upwards price movement, the VWMA should be greater than the SMA during a volume-supported uptrend. Thus, we can confirm an uptrend if the VWMA remains greater than the SMA. If the VWMA falls under the SMA in the midst of an upwards price movement, however, that indicates bearish divergence. The opposite is true for downtrends. If price is decreasing and volume is decreasing at the same time (as it should), then we can confirm the downtrend.
Interpreting the Graph:
If the slow SMA is greater than the slow VWMA, then the area representing the difference between the two lines is filled in red. If the slow VWMA is greater than the slow SMA, however, the area between the two is filled green.
If the fast SMA is greater than the fast VWMA, then the area between the two dotted lines is filled in red. On the other hand, the area will be filled green if the fast VWMA is greater than the slow SMA.
In addition to spotting divergences and confirming trends, the four lines can be used to spot breakouts. Typically, a VWMA crossover will precede the SMA crossover. When the fast VWMA crosses over the slow VWMA and then a SMA crossover follows shortly after, then it is a hint that a bullish trend is beginning to form.
Volume Weighted ALMA TRIX MACDMACD constructed using volume weighted(optional) ALMA TRX
---------------------------------------
If you find it useful please consider a tip/donation :
BTC - 3BMEXEDyWJ58eXUEALYPadbn1wwWKmf6sA
Volume Weighted ALMA TRIXVolume weighted (optional) ALMA "TRIX"
---------------------------------------
If you find it useful please consider a tip/donation :
BTC - 3BMEXEDyWJ58eXUEALYPadbn1wwWKmf6sA
Volume Weighted ALMA RibbonsVolume weighted version of ALMA Ribbons script found here
-------------------------------------------------------
If you find it useful please consider a tip/donation to the rumpy liquidation recovery fund : BTC - 3BMEXEDyWJ58eXUEALYPadbn1wwWKmf6sA
Balihuntul Normalized Absolute Volume by RRBBalihuntul Normalized Absolute Volume by RagingRocketBull 2018
Version 1.0
This indicator shows absolute and/or normalized volume for an asset, allows for more accurate volume based comparisons (like a log scale for volume).
Volume is measured in coins traded, not USD traded, so direct comparisons of different price moves may not be accurate.
Professional traders usually compare absolute or normalized volumes of trend moves/spikes/dips/capitulation events instead.
When the USD price of an asset is lower you can trade more coins but capitalization won't be as significant as when there are less coins for a higher price.
Similarly, you can normalize volume using:
- price/price ma (to get a bit of a price-weighted volume) or
- volume ma to compare it with its average assuming the total volume is a percentage above or below the MA (100% or 1).
- use alpha multiplier to add/lose a few zeroes if necessary
Features:
- Use Absolute Price Value (Price * Volume) of an asset instead of Coins Traded (Volume) to compare capitalization
- Normalize volume using Price / Price MA / Volume MA
- Supports any existing type of MA: SMA, EMA, WMA, HMA etc
- Oscillator mode with negative axis
- Highlight high volume spikes above MA or hide low volume bars below MA
- Change color based on prev Close or Volume bars
- Change Volume MA color based on a number of last rising/falling bars
- Display volume as 1000s, mlns, or blns using alpha multiplier
Notes:
1. uses plot* and custom hma functions
2. swma has a fixed length = 4, alma and linreg have additional offset and smoothing params
Feel free to use. Good Luck!
VW-MACDHello traders!
I am reading "Investing with Volume Analysis: Identify, Follow, and Profit from Trends" by Buff Pelz Dormeier so I am going to implement all indicators that are considered there.
VW-MACD was developed by Buff Pelz Dormeier in 2000 and is based on the difference between a short-term volume-weighted moving average and a long-term volume-weighted moving average. The signal line is traditionally left as an exponential moving average.
Like and follow for more cool indicators!
Happy Trading!
Hamming Windowed Volume Weighted Moving AverageApplying a window to the filter weights provides sometimes extra control over the characteristics of the filter.In this script an hamming window is applied to the volume before being used as a weight.In general this process smooth the frequency response of a filter.
Lets compare the classic vwma with hamming windowed vwma
Something i noticed is that windowed filters depending on their period ( high ones in general ) tend to make less bad crosses with the price ( at least with the hamming window )
Here are some data regarding number of crosses with period 50 with the hamming vwma in orange and the classic vwma in purple
Feel free to use the hamming window when using weighted filter.
Advanced Keltner ChannelsThis is a more advanced version of the standard Keltner Channels indicator. It allows you to change the type of the moving average (Simple, Exponential, Weighted, Volume-weighted, Triple EMA or a moving average that uses RSI ). The indicator also allows you to volume weight the indicator (turned on by default). If you want to weight the indicator against the true range instead of volume this is also possible. By default, this will be done automatically for assets that do not support volume .
Advanced Bollinger BandsThis is a more advanced version of the standard Bollinger Bands indicator. It allows you to change the type of the moving average (Simple, Exponential, Weighted, Volume-weighted, Triple EMA or a moving average that uses RSI ). The indicator also allows you to volume weight the indicator (turned on by default). If you want to weight the oscillator against the true range instead of volume this is also possible. By default, this will be done automatically for assets that do not support volume .