INEVITRADE Pro +INEVITRADE Pro + is an augmented version of standard Relative Strength Index ( RSI ) enhanced with a EMA cloud and some momentum background highlights & Strength Vs. Bitcoin as an added integration.
M-oscillator
Stable Coin Dominance RSIThe Stable Coin Dominance RSI evaluates the relative dominance of stable coins within the crypto ecosystem as compared to the total market cap. As stable coin dominance rises, it suggests that market participants are exiting out of crypto assets and into dollar pegged stable coins. The opposite is true inversely; as stable coin dominance diminishes, it suggests that market participants are divesting out of stable coins and into crypto assets.
Stable coin dominance can be expressed as a percentage of the total market cap as follows: Stable Coins / Total Crypto. The Stable Coin Dominance RSI indicator uses this percentage and converts it into an oscillator using the formula for the relative strength index.
The calculation for the indicator is: RSI
The users can select from USDT and USDC, two most dominant stable tokens by market cap, and compare their relative dominance against Bitcoin and the alt market.
The Stable Coin Dominance RSI may be useful on larger timeframes when attempting to identify the market’s appetite for risk along with oversold and undersold readings which may indicate pivots or turn arounds along market extremes.
The limitation of the indicator lies in the fact that stable coins continue to make up a growing percentage of the total market cap over time and thus comparisons to earlier cycles will not be a perfect apples-to-apples evaluation. This being said, the smoothing function of the RSI’s look back helps to moderate these comparative differences.
Ultimate Oscillator + Realtime DivergencesUltimate Oscillator (UO) + Realtime Divergences + Alerts + Lookback periods.
This version of the Ultimate Oscillator adds the following 5 additional features to the stock UO by Tradingview:
- Optional divergence lines drawn directly onto the oscillator in realtime
- Configurable alerts to notify you when divergences occur, as well as centerline crossovers.
- Configurable lookback periods to fine tune the divergences drawn in order to suit different trading styles and timeframes.
- Background colouring option to indicate when the UO has crossed the centerline, or optionally when both the UO and an external oscillator, which can be linked via the settings, have both crossed their centerlines.
- Alternate timeframe feature allows you to configure the oscillator to use data from a different timeframe than the chart it is loaded on.
This indicator adds additional features onto the stock Ultimate Oscillator by Tradingview, whose core calculations remain unchanged. Namely the configurable option to automatically and clearly draw divergence lines onto the oscillator for you as they occur in realtime. It also has the addition of unique alerts, so you can be notified as divergences occur without spending all day watching the charts. Furthermore, this version of the Ultimate Oscillator comes with configurable lookback periods, which can be configured in order to adjust the length of the divergences, in order to suit shorter or higher timeframe trading approaches.
The Ultimate Oscillator
Tradingview describes the Ultimate Oscillator as follows:
“The Ultimate Oscillator indicator (UO) indicator is a technical analysis tool used to measure momentum across three varying timeframes. The problem with many momentum oscillators is that after a rapid advance or decline in price, they can form false divergence trading signals. For example, after a rapid rise in price, a bearish divergence signal may present itself, however price continues to rise. The ultimate Oscillator attempts to correct this by using multiple timeframes in its calculation as opposed to just one timeframe which is what is used in most other momentum oscillators.”
More information on the history, use cases and calculations of the Ultimate Oscillator can be found here: www.tradingview.com
What are divergences?
Divergence is when the price of an asset is moving in the opposite direction of a technical indicator, such as an oscillator, or is moving contrary to other data. Divergence warns that the current price trend may be weakening, and in some cases may lead to the price changing direction.
There are 4 main types of divergence, which are split into 2 categories;
regular divergences and hidden divergences. Regular divergences indicate possible trend reversals, and hidden divergences indicate possible trend continuation.
Regular bullish divergence: An indication of a potential trend reversal, from the current downtrend, to an uptrend.
Regular bearish divergence: An indication of a potential trend reversal, from the current uptrend, to a downtrend.
Hidden bullish divergence: An indication of a potential uptrend continuation.
Hidden bearish divergence: An indication of a potential downtrend continuation.
Setting alerts.
With this indicator you can set alerts to notify you when any/all of the above types of divergences occur, on any chart timeframe you choose.
Configurable lookback values.
You can adjust the default lookback values to suit your prefered trading style and timeframe. If you like to trade a shorter time frame, lowering the default lookback values will make the divergences drawn more sensitive to short term price action.
How do traders use divergences in their trading?
A divergence is considered a leading indicator in technical analysis , meaning it has the ability to indicate a potential price move in the short term future.
Hidden bullish and hidden bearish divergences, which indicate a potential continuation of the current trend are sometimes considered a good place for traders to begin, since trend continuation occurs more frequently than reversals, or trend changes.
When trading regular bullish divergences and regular bearish divergences, which are indications of a trend reversal, the probability of it doing so may increase when these occur at a strong support or resistance level . A common mistake new traders make is to get into a regular divergence trade too early, assuming it will immediately reverse, but these can continue to form for some time before the trend eventually changes, by using forms of support or resistance as an added confluence, such as when price reaches a moving average, the success rate when trading these patterns may increase.
Typically, traders will manually draw lines across the swing highs and swing lows of both the price chart and the oscillator to see whether they appear to present a divergence, this indicator will draw them for you, quickly and clearly, and can notify you when they occur.
Disclaimer: This script includes code from the stock UO by Tradingview as well as the Divergence for Many Indicators v4 by LonesomeTheBlue.
True Strength Indicator + Realtime DivergencesTrue Strength Indicator (TSI) + Realtime Divergences + Alerts + Lookback periods.
This version of the True Strength Indicator adds the following 5 additional features to the stock TSI by Tradingview:
- Optional divergence lines drawn directly onto the oscillator in realtime.
- Configurable alerts to notify you when divergences occur, as well as when the TSI and lagline bands crossover one another, when the oscillator begins heading up, or heading down.
- Configurable lookback periods to fine tune the divergences drawn in order to suit different trading styles and timeframes.
- Background colouring option to indicate when the two TSI bands, the TSI line and the TSI lagline, have crossed one another, either moving upwards or downwards, or optionally when the two TSI bands have crossed upwards and an external oscillator, which can be linked via the settings, has crossed above its centerline, and the TSI bands have crossed downwards and the external oscillator has crossed below its centerline.
- Alternate timeframe feature allows you to configure the oscillator to use data from a different timeframe than the chart it is loaded on.
This indicator adds additional features onto the stock TSI by Tradingview, whose core calculations remain unchanged, although this version has different settings as default to suit a shorter time period (it uses 6, 13, 4 by default, whereas the stock TSI typically ships with higher values, e.g. 25, 13, 13). Namely the configurable option to automatically, quickly and clearly draw divergence lines onto the oscillator for you as they occur in realtime. It also has the addition of unique alerts, so you can be notified when divergences occur without spending all day watching the charts. Furthermore, this version of the TSI comes with configurable lookback periods, which can be configured in order to adjust the sensitivity of the divergences, in order to suit shorter or higher timeframe trading approaches.
The True Strength Indicator
Tradingview describes the True Strength Indicator as follows:
“The True Strength Index (TSI) is a momentum oscillator that ranges between limits of -100 and +100 and has a base value of 0. Momentum is positive when the oscillator is positive (pointing to a bullish market bias) and vice versa. It was developed by William Blau and consists of 2 lines: the index line and an exponential moving average of the TSI, called the signal line. Traders may look for any of the following 5 types of conditions: overbought, oversold, centerline crossover, divergence and signal line crossover. The indicator is often used in combination with other signals..”
What are divergences?
Divergence is when the price of an asset is moving in the opposite direction of a technical indicator, such as an oscillator, or is moving contrary to other data. Divergence warns that the current price trend may be weakening, and in some cases may lead to the price changing direction.
There are 4 main types of divergence, which are split into 2 categories;
regular divergences and hidden divergences. Regular divergences indicate possible trend reversals, and hidden divergences indicate possible trend continuation.
Regular bullish divergence: An indication of a potential trend reversal, from the current downtrend, to an uptrend.
Regular bearish divergence: An indication of a potential trend reversal, from the current uptrend, to a downtrend.
Hidden bullish divergence: An indication of a potential uptrend continuation.
Hidden bearish divergence: An indication of a potential downtrend continuation.
Setting alerts.
With this indicator you can set alerts to notify you when any/all of the above types of divergences occur, on any chart timeframe you choose.
Configurable lookback values.
You can adjust the default lookback values to suit your prefered trading style and timeframe. If you like to trade a shorter time frame, lowering the default lookback values will make the divergences drawn more sensitive to short term price action.
How do traders use divergences in their trading?
A divergence is considered a leading indicator in technical analysis , meaning it has the ability to indicate a potential price move in the short term future.
Hidden bullish and hidden bearish divergences, which indicate a potential continuation of the current trend are sometimes considered a good place for traders to begin, since trend continuation occurs more frequently than reversals, or trend changes.
When trading regular bullish divergences and regular bearish divergences, which are indications of a trend reversal, the probability of it doing so may increase when these occur at a strong support or resistance level . A common mistake new traders make is to get into a regular divergence trade too early, assuming it will immediately reverse, but these can continue to form for some time before the trend eventually changes, by using forms of support or resistance as an added confluence, such as when price reaches a moving average, the success rate when trading these patterns may increase.
Typically, traders will manually draw lines across the swing highs and swing lows of both the price chart and the oscillator to see whether they appear to present a divergence, this indicator will draw them for you, quickly and clearly, and can notify you when they occur.
Disclaimer: This script includes code from the stock TSI by Tradingview as well as the Divergence for Many Indicators v4 by LonesomeTheBlue
Indian Bank Nifty ScreenerIndian Bank Nifty Screener (IBNS) is a comprehensive table displaying the following parameters for Bank Nifty constituents:
Op = Open Price of the Day.
LaP = Last Price.
O-L = Open Price of the Day - Last Price.
ROC = Rate of Change .
SMA20 = Simple Moving Average 20 period.
S20d = Last Price - SMA 20.
SMA50 = Simple Moving Average 50 period.
S50d = Last Price - SMA 50.
SMA200 = Simple Moving Average 200 period.
S200d = Last Price - SMA 200.
ADX(14) = Average Directional Index.
RSI(14) = Relative Strength Index.
CCI(20) = Commodity Channel Index.
ATR(14) = Average True Range.
MOM(10) = Momentum.
CMF(20) = Chaikin Money Flow.
MACD = Moving Average Convergence Divergence.
Sig = MACD signal.
The first row displays individual banks on selection from Input Box in “Settings”.
User after visiting the “Settings” menu simply is required to select the “input symbol” from the stock listed in the “Option” Box. Automatically the selected bank name with parameter details is displayed in first row.
The other rows starting with “Nifty50” and with ” Bank Nifty” in second row, displays static individual Bank Nifty stocks starting from third row.
RSI Momentum Acceleration by TartigradiaPlots the momentum acceleration oscillators from price and RSI, rescaled and with areas above/below highlighted.
Usage: in a nutshell, when the background is yellow, it's bearish (RSI decelerates faster than price), whereas when the background is green, it's bullish (RSI accelerates faster than price). It appears to detect early some reversals that are otherwise difficult to detect.
Note: it supports using any other indicator's output as the second source input, instead of RSI. PineScript does not allow for more than one source to receive input from other indicators, all the others must only use price as an input.
This indicator uses the core routine to calculate Momentum Acceleration Oscillators by DGT:
This indicator is based on the idea of stinkbug : "RSI is a good momentum indicator showing how excited ppl are on a move, this is why divergences on it work so well. I would like to see the change accelerating or slowing on a move up or down.."
Indicator Cheat ModeThis script looks at the Stoich, the RSI and the MacD and 1 time period previous MacD to determine if bottom has been reached. Use at own discression and performs better on longer timeframes like most osscilators. Try 1 hour and 4 hour, small time frames give more false readings.
Sharpe Ratio v4I'm publishing this indicator freely, because I'd like to get it reviewed by other people. This indicator was written whilst reading the book Systematic Trading by Robert Carver. In this book Carver describes trading rules that use a "dynamic" position size based on something like an evolving Sharpe Ratio . There are only a few other Sharpe indicators on TradingView, but they are either undocumented or use closed source code. You can use the following code as you wish for your own projects.
I'd like to let other people see this work, and let me know where they think this script is wrong, so that I can improve it.
Here's a basic rundown of Sharpe Ratio and its calculation.
SR is defined as: (excess) return minus the risk free rate divided by standard deviation of those returns. (This is where we're uncertain. Is the standard deviation of the returns, or just the closes?) But anyway the calculation itself is pretty simple:
SR = (r – b) ÷ s
Where r is the return of the asset over a certain period.
b is the interest rate of the risk-free asset.
s is the standard deviation of the returns over the same period.
For this indicator to "work" correctly, we're assuming the risk-free rate is 0. In fact, I did not include b at all in the indicator because it would make things too complicated, and go beyond the aim of this work.
To calculate the returns over a certain period, I'm using Rate of Change. Then calculating the standard deviation of those returns is pretty easy because we can use the same lookback period we used for ROC for the StDev calculation, thus:
averageReturn = ta.roc(close, lookbackLength)
stdev = ta.stdev(averageReturn, lookbackLength)
sharpe = (averageReturn / stdev)
Please leave a comment below if you believe this is incorrect. The chart shows a normal ROC indicator for comparison. I've also created a "bands" version of this indicator, which I'm planning to also release. The Keltner channel is just for comparing it with the StDev bands.
Tickers Info ExtensionWith the indicator you can easily evaluate or compare any ticker with the one you choose in the options.
You can choose any of the tickers I provide in the mod options to your liking :
XAU
DXY
BTC
ETH
SPX
NASDAQ
AVG Stable Dominance
AVG Stock Price
Custom
You can also select or create your own ticker if you select the Custom in Mode option.
If the Compare mode is enabled, then the current ticker you are viewing is divided by the ticker selected in the indicator (in the Mode option).
Thus, you create a new pair and can evaluate the strength of this or that asset.
For example, if you have the ticker BTCUSDT open. And the ticker XAU is selected in the Mode option in the indicator. And the Compare mode is also enabled. Then you will get a new BTCUSDT/XAU pair. That means that now you can see the bitcoin/gold ratio. (Same as EUR/USD etc.)
If the Compare option is switched off then you will see the usual ticker you choose in the Mode option. You can also see if there is a correlation between the selected pairs.
Option ' AVG STABLE.D ' = Calculated as: USDT.D + USDC.D + DAI.D
- This is the average domination of the most important Stable Coins
Option ' AVG STOCK Price ' = Calculated as: (DJI + SPX + NDQ) / 3
- This is the average price of the most important Indexes.
HPK Crash IndicatorFrom Hari P. Krishnan's book, The Second Leg Down: Strategies for Profiting after a Market Sell-Off :
"We start by specifying the year on year (YoY) change in the index. Next, we calculate the 5 year trailing Z score of the YoY returns. We also calculate the 5 year trailing Z score of 1 month historical volatility for the index, using daily returns. Our crisis warning indicator flashes if both Z scores are above 2. In other words, recent price increases and current volatility need to be at least 2 standard deviations above normal.
It can be seen that this basic implementation is reasonably effective, accepting that the effective sample set is small. A false signal is given in mid-2006, but the signal is quickly washed away. The remaining signals occur fairly close to the point of collapse. The idea that elevated volatility is predictive of danger is not new and underpins many asset allocation schemes. However, Sornette deserves credit for moving away from a largely valuation-based approach to predicting crises to one that relies upon price action itself."
Mansfield Relative Strength (Original Version) by stageanalysisThe Mansfield Relative Strength ( Mansfield RS ) is one of the core components of the Stan Weinstein's Stage Analysis method as discussed in his classic book Stan Weinstein's Secrets for Profiting in Bull and Bear Markets .
The Mansfield RS measures the relative performance of the stock compared to an index such as the S&P 500, or to another stock etc.
However, this should not to be confused with the popular RSI (Relative Strength Index developed J. Welles Wilder), which is a momentum oscillator that measures the speed and change of price movements on a single stock.
The Mansfield RS indicator consists of the Relative Strength comparison line versus the S&P 500 (default universal setting, but can be edited), and the "Zero Line" – which is the 52 week MA of the Relative Strength line, that's been flattened to create the oscillator style.
How to use the Indicator:
Outperforming – Above the Zero Line
When the Relative Strength line crosses above the Zero Line (it's flattened 52 week RS MA), it is outperforming the index or stock that it's comparing against, and so it is showing stronger relative strength.
Underperforming – Below the Zero Line
When the Relative Strength line crosses below the Zero Line (it's flattened 52 week RS MA), it is underperforming the index or stock that it's comparing against, and so it is showing weaker relative strength.
Settings:
When you first add the indicator is has a coloured background, with a green tint for a postive RS score, and a red tint for a negative RS score. However, this can be turned off, or edited in the indicator settings, in the Style tab. So you can change the colors or remove it and just have the RS line and zero line showing. Both of which can also be edited in the settings.
Change the symbol that it compares against. The default is the S&P 500. But for crypto you might want to use Bitcoin for example. Or you might want to compare against competing stocks in the same peer group, or against the industry group or sector. The choice is yours. But the S&P 500 is a universal measure for the Mansfield RS. So I would recommend leaving it on that unless you have a particular reason to change it as mentioned.
MA Length is also an editable setting. This creates the Zero Line. So it will affect the values of the Mansfield RS if you change it. 52 is the default setting, and is set as such for the weekly chart. So I'd recommend not editing it on the weekly chart, but for other timeframes, different settings can be used.
ETS Price Deviation Reversal AreasThis indicator tracks the degree to which price moves away from an average and triggers potential direction changes based on standard deviation levels.
The reason I created this script is because I wanted to see how far price moved away from the moving average in a more clearly defined way than just saying "wow, price is pretty far away from the 9 EMA..." or whichever moving average you were looking at.
Typically when price moves "too far" away from the moving averages, it corrects itself, I think mainly because a lot of people say "wow, price is pretty far away from the 9 EMA..." and then enter a trade. This indicator tries to make it easier to see when that switches around, which could indicate that price will be reversing.
Of course the indicator is not a silver bullet, but I have found it pretty useful and I hope that you do too!
It also tries to avoid giving signals when prices are in a very small range. When the deviation bars contract, the indicator switches to only signal "breakout" type moves to try and limit whipsaw signals.
The smaller dots are spots that could indicate a potentially early reversal, and the larger dots show up a bit later when the reversal is a bit more established. There are also alerts that you can use if you want.
Change this code as you want to, but please let the community know and send me a message if you found something to share! Thanks!
[blackcat] L1 Leavitt Convolution SlopeLevel 1
Background
First of all, I would like to thank @ashok1961 for his donation. Second, he made an interesting request: can I write a pine version of LeavittConvSlope.
Function
The indicator uses linear regression of price data to derive slope and acceleration information that helps traders spot trends and turning points. After trying this metric myself, I think it works better with the divergence detector. So I added it. Let me know what you think of this divergence detector.
Remarks
Feedbacks are appreciated.
+ Dynamic Fibo-Donchian ChannelsThis is my second Donchian Channels indicator (and will probably be my last because how many does one really need). This version is different from my other one in that, well, it's 'dynamic' which simply means that it self adjusts based on the same formula that my Ultimate Moving Average does. What does that mean? It just means that the script takes an average of 8 different length, in this case, highest highs and lowest lows. The user doesn't need to pick a lookback/length/period/what-have-you. The indicator does it all itself. This, I think, makes for a very nice baseline or bias indicator to fit within a system that utilizes something like that. I also think it makes for a more accurate gauge of higher highs and lower lows within a timeframe, because honestly what does it mean to make a lower low over 20 periods or 8 periods or 50 periods? I don't know. What I do know is that traditional Donchian Channels never made much sense to me, but this does.
Additionally, I've kept (I guess that's not 'additionally') the fibonacci retracement levels from my other Donchian Channels indicator. These are calculated off the high and the low of the Donchian Channels themselves. You will see that there are only three retracement levels (.786, .705, .382), one of which is not a fib level, but what some people call the 'OTE,' or 'optimal trade entry.'' If you want more info on the OTE just web search it. So, why no .618 or .236? Reason being that the .618 overlaps the .382, and the .236 is extremely close to the .786. This sounds confusing, but the retracement levels I'm using are derived from the high and low, so it was unnecessary to have all five levels from each. I could have just calculated from the high, or just from the low, and used all the levels, but I chose to just calculate three levels from the high and three from the low because that gives a sort of mirror image balance, and that appeals to me, and the utility of the indicator is the same.
The plot lines are all colored, and I've filled certain zones between them. There is a center zone filled between both .382 levels, an upper and lower zon filled between the .786 and either the high or the low, and a zone between the .705 and .785
If you like the colored zones, but don't like the plots because they cause screen compression, turn off the plots under the "style" tab, or much more simply right click on the price scale and click 'scale price chart only.' Voila! No more screen compression due to a moving average or some other annoyance.
Besides that basis being a nice baseline indicator the various fib bands (or just the high and low bands) make for excellent mean reversion extremes in ranging environments.
There are alerts for candle closes across every line.
Below is an image of the indicator at default settings.
Below is an image of the indicator with the center .382 channel turned off.
Below is an image of the indicator with just the .786/.705 channel showing .
Stochastic GuppyDerived from TradingView's built-in Stochastic indicator. Switched from SMA to EMA and applied Guppy (GMMA) indicator short and long term periods.
RSI mid partition color changeWhen RSI is above 50 our default bias is on buy side and when below 50 our bias is on sell side.
Therefore created 2 zones for easy identification.
Kase Peak Oscillator w/ Divergences [Loxx]Kase Peak Oscillator is unique among first derivative or "rate-of-change" indicators in that it statistically evaluates over fifty trend lengths and automatically adapts to both cycle length and volatility. In addition, it replaces the crude linear mathematics of old with logarithmic and exponential models that better reflect the true nature of the market. Kase Peak Oscillator is unique in that it can be applied across multiple time frames and different commodities.
As a hybrid indicator, the Peak Oscillator also generates a trend signal via the crossing of the histogram through the zero line. In addition, the red/green histogram line indicates when the oscillator has reached an extreme condition. When the oscillator reaches this peak and then turns, it means that most of the time the market will turn either at the present extreme, or (more likely) at the following extreme.
This is both a reversal and breakout/breakdown indicator. Crosses above/below zero line can be used for breakouts/breakdowns, while the thick green/red bars can be used to detect reversals
The indicator consists of three indicators:
The PeakOscillator itself is rendered as a gray histogram.
Max is a red/green solid line within the histogram signifying a market extreme.
Yellow line is max peak value of two (by default, you can change this with the deviations input settings) standard deviations of the Peak Oscillator value
White line is the min peak value of two (by default, you can change this with the deviations input settings) standard deviations of the PeakOscillator value
The PeakOscillator is used two ways:
Divergence: Kase Peak Oscillator may be used to generate traditional divergence signals. The difference between it and traditional divergence indicators lies in its accuracy.
PeakOut: The second use is to look for a Peak Out. A Peak Out occurs when the histogram breaks beyond the PeakOut line and then pulls back. A Peak Out through the maximum line will be displayed magenta. A Peak Out, which only extends through the Peak Min line is called a local Peak Out, and is less significant than a normal Peak Out signal. These local Peak Outs are to be relied upon more heavily during sideways or corrective markets. Peak Outs may be based on either the maximum line or the minimum line. Maximum Peak Outs, however, are rarer and thus more significant than minimum Peak Outs. The magnitude of the price move may be greater following the maximum Peak Out, but the likelihood of the break in trend is essentially the same. Thus, our research indicates that we should react equally to a Peak Out in a trendy market and a Peak Min in a choppy or corrective market.
Included:
Bar coloring
Alerts
HMA Slope Variation [Loxx]HMA Slope Variation is an indicator that uses HMA moving average to calculate a slope that is then weighted to derive a signal.
The center line
The center line changes color depending on the value of the:
Slope
Signal line
Threshold
If the value is above a signal line (it is not visible on the chart) and the threshold is greater than the required, then the main trend becomes up. And reversed for the trend down.
Colors and style of the histogram
The colors and style of the histogram will be drawn if the value is at the right side, if the above described trend "agrees" with the value (above is green or below zero is red) and if the High is higher than the previous High or Low is lower than the previous low, then the according type of histogram is drawn.
What is the Hull Moving Average?
The Hull Moving Average ( HMA ) attempts to minimize the lag of a traditional moving average while retaining the smoothness of the moving average line. Developed by Alan Hull in 2005, this indicator makes use of weighted moving averages to prioritize more recent values and greatly reduce lag.
Included
Alets
Signals
Bar coloring
Loxx's Expanded Source Types
T3 Slope Variation [Loxx]T3 Slope Variation is an indicator that uses T3 moving average to calculate a slope that is then weighted to derive a signal.
The center line
The center line changes color depending on the value of the:
Slope
Signal line
Threshold
If the value is above a signal line (it is not visible on the chart) and the threshold is greater than the required, then the main trend becomes up. And reversed for the trend down.
Colors and style of the histogram
The colors and style of the histogram will be drawn if the value is at the right side, if the above described trend "agrees" with the value (above is green or below zero is red) and if the High is higher than the previous High or Low is lower than the previous low, then the according type of histogram is drawn.
What is the T3 moving average?
Better Moving Averages Tim Tillson
November 1, 1998
Tim Tillson is a software project manager at Hewlett-Packard, with degrees in Mathematics and Computer Science. He has privately traded options and equities for 15 years.
Introduction
"Digital filtering includes the process of smoothing, predicting, differentiating, integrating, separation of signals, and removal of noise from a signal. Thus many people who do such things are actually using digital filters without realizing that they are; being unacquainted with the theory, they neither understand what they have done nor the possibilities of what they might have done."
This quote from R. W. Hamming applies to the vast majority of indicators in technical analysis . Moving averages, be they simple, weighted, or exponential, are lowpass filters; low frequency components in the signal pass through with little attenuation, while high frequencies are severely reduced.
"Oscillator" type indicators (such as MACD , Momentum, Relative Strength Index ) are another type of digital filter called a differentiator.
Tushar Chande has observed that many popular oscillators are highly correlated, which is sensible because they are trying to measure the rate of change of the underlying time series, i.e., are trying to be the first and second derivatives we all learned about in Calculus.
We use moving averages (lowpass filters) in technical analysis to remove the random noise from a time series, to discern the underlying trend or to determine prices at which we will take action. A perfect moving average would have two attributes:
It would be smooth, not sensitive to random noise in the underlying time series. Another way of saying this is that its derivative would not spuriously alternate between positive and negative values.
It would not lag behind the time series it is computed from. Lag, of course, produces late buy or sell signals that kill profits.
The only way one can compute a perfect moving average is to have knowledge of the future, and if we had that, we would buy one lottery ticket a week rather than trade!
Having said this, we can still improve on the conventional simple, weighted, or exponential moving averages. Here's how:
Two Interesting Moving Averages
We will examine two benchmark moving averages based on Linear Regression analysis.
In both cases, a Linear Regression line of length n is fitted to price data.
I call the first moving average ILRS, which stands for Integral of Linear Regression Slope. One simply integrates the slope of a linear regression line as it is successively fitted in a moving window of length n across the data, with the constant of integration being a simple moving average of the first n points. Put another way, the derivative of ILRS is the linear regression slope. Note that ILRS is not the same as a SMA ( simple moving average ) of length n, which is actually the midpoint of the linear regression line as it moves across the data.
We can measure the lag of moving averages with respect to a linear trend by computing how they behave when the input is a line with unit slope. Both SMA (n) and ILRS(n) have lag of n/2, but ILRS is much smoother than SMA .
Our second benchmark moving average is well known, called EPMA or End Point Moving Average. It is the endpoint of the linear regression line of length n as it is fitted across the data. EPMA hugs the data more closely than a simple or exponential moving average of the same length. The price we pay for this is that it is much noisier (less smooth) than ILRS, and it also has the annoying property that it overshoots the data when linear trends are present.
However, EPMA has a lag of 0 with respect to linear input! This makes sense because a linear regression line will fit linear input perfectly, and the endpoint of the LR line will be on the input line.
These two moving averages frame the tradeoffs that we are facing. On one extreme we have ILRS, which is very smooth and has considerable phase lag. EPMA has 0 phase lag, but is too noisy and overshoots. We would like to construct a better moving average which is as smooth as ILRS, but runs closer to where EPMA lies, without the overshoot.
A easy way to attempt this is to split the difference, i.e. use (ILRS(n)+EPMA(n))/2. This will give us a moving average (call it IE /2) which runs in between the two, has phase lag of n/4 but still inherits considerable noise from EPMA. IE /2 is inspirational, however. Can we build something that is comparable, but smoother? Figure 1 shows ILRS, EPMA, and IE /2.
Filter Techniques
Any thoughtful student of filter theory (or resolute experimenter) will have noticed that you can improve the smoothness of a filter by running it through itself multiple times, at the cost of increasing phase lag.
There is a complementary technique (called twicing by J.W. Tukey) which can be used to improve phase lag. If L stands for the operation of running data through a low pass filter, then twicing can be described by:
L' = L(time series) + L(time series - L(time series))
That is, we add a moving average of the difference between the input and the moving average to the moving average. This is algebraically equivalent to:
2L-L(L)
This is the Double Exponential Moving Average or DEMA , popularized by Patrick Mulloy in TASAC (January/February 1994).
In our taxonomy, DEMA has some phase lag (although it exponentially approaches 0) and is somewhat noisy, comparable to IE /2 indicator.
We will use these two techniques to construct our better moving average, after we explore the first one a little more closely.
Fixing Overshoot
An n-day EMA has smoothing constant alpha=2/(n+1) and a lag of (n-1)/2.
Thus EMA (3) has lag 1, and EMA (11) has lag 5. Figure 2 shows that, if I am willing to incur 5 days of lag, I get a smoother moving average if I run EMA (3) through itself 5 times than if I just take EMA (11) once.
This suggests that if EPMA and DEMA have 0 or low lag, why not run fast versions (eg DEMA (3)) through themselves many times to achieve a smooth result? The problem is that multiple runs though these filters increase their tendency to overshoot the data, giving an unusable result. This is because the amplitude response of DEMA and EPMA is greater than 1 at certain frequencies, giving a gain of much greater than 1 at these frequencies when run though themselves multiple times. Figure 3 shows DEMA (7) and EPMA(7) run through themselves 3 times. DEMA^3 has serious overshoot, and EPMA^3 is terrible.
The solution to the overshoot problem is to recall what we are doing with twicing:
DEMA (n) = EMA (n) + EMA (time series - EMA (n))
The second term is adding, in effect, a smooth version of the derivative to the EMA to achieve DEMA . The derivative term determines how hot the moving average's response to linear trends will be. We need to simply turn down the volume to achieve our basic building block:
EMA (n) + EMA (time series - EMA (n))*.7;
This is algebraically the same as:
EMA (n)*1.7-EMA( EMA (n))*.7;
I have chosen .7 as my volume factor, but the general formula (which I call "Generalized Dema") is:
GD (n,v) = EMA (n)*(1+v)-EMA( EMA (n))*v,
Where v ranges between 0 and 1. When v=0, GD is just an EMA , and when v=1, GD is DEMA . In between, GD is a cooler DEMA . By using a value for v less than 1 (I like .7), we cure the multiple DEMA overshoot problem, at the cost of accepting some additional phase delay. Now we can run GD through itself multiple times to define a new, smoother moving average T3 that does not overshoot the data:
T3(n) = GD ( GD ( GD (n)))
In filter theory parlance, T3 is a six-pole non-linear Kalman filter. Kalman filters are ones which use the error (in this case (time series - EMA (n)) to correct themselves. In Technical Analysis , these are called Adaptive Moving Averages; they track the time series more aggressively when it is making large moves.
Included
Alets
Signals
Bar coloring
Loxx's Expanded Source Types
Multi HMA Slopes [Loxx]Multi HMA Slopes is an indicator that checks slopes of 5 (different period) Hull Moving Averages and adds them up to show overall trend. To us this, check for color changes from red to green where there is no red if green is larger than red and there is no red when red is larger than green. When red and green both show up, its a sign of chop.
What is the Hull Moving Average?
The Hull Moving Average (HMA) attempts to minimize the lag of a traditional moving average while retaining the smoothness of the moving average line. Developed by Alan Hull in 2005, this indicator makes use of weighted moving averages to prioritize more recent values and greatly reduce lag.
Included
Signals: long, short, continuation long, continuation short.
Alerts
Bar coloring
Loxx's expanded source types
Multi T3 Slopes [Loxx]Multi T3 Slopes is an indicator that checks slopes of 5 (different period) T3 Moving Averages and adds them up to show overall trend. To us this, check for color changes from red to green where there is no red if green is larger than red and there is no red when red is larger than green. When red and green both show up, its a sign of chop.
What is the T3 moving average?
Better Moving Averages Tim Tillson
November 1, 1998
Tim Tillson is a software project manager at Hewlett-Packard, with degrees in Mathematics and Computer Science. He has privately traded options and equities for 15 years.
Introduction
"Digital filtering includes the process of smoothing, predicting, differentiating, integrating, separation of signals, and removal of noise from a signal. Thus many people who do such things are actually using digital filters without realizing that they are; being unacquainted with the theory, they neither understand what they have done nor the possibilities of what they might have done."
This quote from R. W. Hamming applies to the vast majority of indicators in technical analysis . Moving averages, be they simple, weighted, or exponential, are lowpass filters; low frequency components in the signal pass through with little attenuation, while high frequencies are severely reduced.
"Oscillator" type indicators (such as MACD , Momentum, Relative Strength Index ) are another type of digital filter called a differentiator.
Tushar Chande has observed that many popular oscillators are highly correlated, which is sensible because they are trying to measure the rate of change of the underlying time series, i.e., are trying to be the first and second derivatives we all learned about in Calculus.
We use moving averages (lowpass filters) in technical analysis to remove the random noise from a time series, to discern the underlying trend or to determine prices at which we will take action. A perfect moving average would have two attributes:
It would be smooth, not sensitive to random noise in the underlying time series. Another way of saying this is that its derivative would not spuriously alternate between positive and negative values.
It would not lag behind the time series it is computed from. Lag, of course, produces late buy or sell signals that kill profits.
The only way one can compute a perfect moving average is to have knowledge of the future, and if we had that, we would buy one lottery ticket a week rather than trade!
Having said this, we can still improve on the conventional simple, weighted, or exponential moving averages. Here's how:
Two Interesting Moving Averages
We will examine two benchmark moving averages based on Linear Regression analysis.
In both cases, a Linear Regression line of length n is fitted to price data.
I call the first moving average ILRS, which stands for Integral of Linear Regression Slope. One simply integrates the slope of a linear regression line as it is successively fitted in a moving window of length n across the data, with the constant of integration being a simple moving average of the first n points. Put another way, the derivative of ILRS is the linear regression slope. Note that ILRS is not the same as a SMA ( simple moving average ) of length n, which is actually the midpoint of the linear regression line as it moves across the data.
We can measure the lag of moving averages with respect to a linear trend by computing how they behave when the input is a line with unit slope. Both SMA (n) and ILRS(n) have lag of n/2, but ILRS is much smoother than SMA .
Our second benchmark moving average is well known, called EPMA or End Point Moving Average. It is the endpoint of the linear regression line of length n as it is fitted across the data. EPMA hugs the data more closely than a simple or exponential moving average of the same length. The price we pay for this is that it is much noisier (less smooth) than ILRS, and it also has the annoying property that it overshoots the data when linear trends are present.
However, EPMA has a lag of 0 with respect to linear input! This makes sense because a linear regression line will fit linear input perfectly, and the endpoint of the LR line will be on the input line.
These two moving averages frame the tradeoffs that we are facing. On one extreme we have ILRS, which is very smooth and has considerable phase lag. EPMA has 0 phase lag, but is too noisy and overshoots. We would like to construct a better moving average which is as smooth as ILRS, but runs closer to where EPMA lies, without the overshoot.
A easy way to attempt this is to split the difference, i.e. use (ILRS(n)+EPMA(n))/2. This will give us a moving average (call it IE /2) which runs in between the two, has phase lag of n/4 but still inherits considerable noise from EPMA. IE /2 is inspirational, however. Can we build something that is comparable, but smoother? Figure 1 shows ILRS, EPMA, and IE /2.
Filter Techniques
Any thoughtful student of filter theory (or resolute experimenter) will have noticed that you can improve the smoothness of a filter by running it through itself multiple times, at the cost of increasing phase lag.
There is a complementary technique (called twicing by J.W. Tukey) which can be used to improve phase lag. If L stands for the operation of running data through a low pass filter, then twicing can be described by:
L' = L(time series) + L(time series - L(time series))
That is, we add a moving average of the difference between the input and the moving average to the moving average. This is algebraically equivalent to:
2L-L(L)
This is the Double Exponential Moving Average or DEMA , popularized by Patrick Mulloy in TASAC (January/February 1994).
In our taxonomy, DEMA has some phase lag (although it exponentially approaches 0) and is somewhat noisy, comparable to IE /2 indicator.
We will use these two techniques to construct our better moving average, after we explore the first one a little more closely.
Fixing Overshoot
An n-day EMA has smoothing constant alpha=2/(n+1) and a lag of (n-1)/2.
Thus EMA (3) has lag 1, and EMA (11) has lag 5. Figure 2 shows that, if I am willing to incur 5 days of lag, I get a smoother moving average if I run EMA (3) through itself 5 times than if I just take EMA (11) once.
This suggests that if EPMA and DEMA have 0 or low lag, why not run fast versions (eg DEMA (3)) through themselves many times to achieve a smooth result? The problem is that multiple runs though these filters increase their tendency to overshoot the data, giving an unusable result. This is because the amplitude response of DEMA and EPMA is greater than 1 at certain frequencies, giving a gain of much greater than 1 at these frequencies when run though themselves multiple times. Figure 3 shows DEMA (7) and EPMA(7) run through themselves 3 times. DEMA^3 has serious overshoot, and EPMA^3 is terrible.
The solution to the overshoot problem is to recall what we are doing with twicing:
DEMA (n) = EMA (n) + EMA (time series - EMA (n))
The second term is adding, in effect, a smooth version of the derivative to the EMA to achieve DEMA . The derivative term determines how hot the moving average's response to linear trends will be. We need to simply turn down the volume to achieve our basic building block:
EMA (n) + EMA (time series - EMA (n))*.7;
This is algebraically the same as:
EMA (n)*1.7-EMA( EMA (n))*.7;
I have chosen .7 as my volume factor, but the general formula (which I call "Generalized Dema") is:
GD (n,v) = EMA (n)*(1+v)-EMA( EMA (n))*v,
Where v ranges between 0 and 1. When v=0, GD is just an EMA , and when v=1, GD is DEMA . In between, GD is a cooler DEMA . By using a value for v less than 1 (I like .7), we cure the multiple DEMA overshoot problem, at the cost of accepting some additional phase delay. Now we can run GD through itself multiple times to define a new, smoother moving average T3 that does not overshoot the data:
T3(n) = GD ( GD ( GD (n)))
In filter theory parlance, T3 is a six-pole non-linear Kalman filter. Kalman filters are ones which use the error (in this case (time series - EMA (n)) to correct themselves. In Technical Analysis , these are called Adaptive Moving Averages; they track the time series more aggressively when it is making large moves.
Included
Signals: long, short, continuation long, continuation short.
Alerts
Bar coloring
Loxx's expanded source types
Cumulative Delta Volume RSI-8 CandlesThis script combines Cumulative delta volume information and the RSI set to an 8 period look back to show momentum in the market. It is displayed using a color overlay with 3 colors. Green candles indicate positive market momentum along with positive delta and positive price movement. Red candles indicate negative market momentum along with negative delta and negative price movement. Yellow candles indicate possible ranging conditions or the start of a pullback in either direction. There is also a moving average built into the indicator to help with trend direction.
Combined with price action strategies or even simple moving averages this indicator can be used as a powerful confirmation or confluence in any trading system. Works nicely to confirm breakout strategies as well.
Can be used on any market or time frame though for price action strategies it works best on time frames H1 and under.
Zero-line Volatility Quality Index (VQI) [Loxx]Originally volatility quality was invented by Thomas Stridsman, and he uses it in combination of two averages.
This version:
This doesn't use averages for trend estimation, but instead uses the slope of the Volatility quality. In order to lessen the number of signals (which can be enormous if the VQ is not filtered), some versions similar to this are using pips filters. This version is using % ATR (Average True Range) instead. The reason for that is that :
Using fixed pips value as a filter will work on one symbol and will not work on another
Changing time frames will render the filter worthless since the ranges of higher time frames are much greater than those at lower time frames, and, when you set your filter on one time frame and then try it on another, it is almost certain that it will have to be adjusted again
Additionally, this version is made to oscillate around zero line (which makes the potential levels, which are even in the original Stridsman's version doubtful, unnecessary)
Usage:
You can use the color change as signals when using this indicator