convolution
Description:
Convolution indicators aim to identify a major reversal in the price direction so that one can trade the market primarily in the direction of the ensuing trend, as described in the Cycle Analytics for Traders, by John F. Ehlers pg. 165. The notion is based on the concept of the two price segments are perfectly correlated (cross-correlated) that have been folded at the horizontal point, since high correlation exists only at the market turning point, e.g. price decreases linearly until the bottom is reached and then increases linearly after the bottom occurs and vice versa. The vertical scale is the lookback period, while the value is converted to colors.
Features:
High-pass filter and Smoothing function on the input data
Major reversals are identified by plumes pointing backward to the time of the price reversal
Bullish reversal identified by the green color of the indicator,
while Bearish reversal identified by a red color dominated the indicator
Convolution
Leavitt Convolution Slope [CC]The Leavitt Convolution Slope indicator was created by Jay Leavitt (Stocks and Commodities Oct 2019, page 11), who is most well known for creating the Volume-Weighted Average Price indicator. This indicator is very similar to the Leavitt Convolution indicator but the big difference is that it is getting the slope instead of predicting the next Convolution value. I changed quite a few things from the original source code so let me know if you like these changes. I added a normalization function using code from a good friend @loxx that I recommend to leave on but feel free to experiment with it. Last but not least, the unsure levels are essentially acting as a buy or sell threshold. I personally recommend to buy or sell for zero crossovers but another option would be to buy or sell for crossovers using the unsure levels. I have color coded the lines to turn light green for a normal buy signal or dark green for a strong buy signal and light red for a normal sell signal, and dark red for a strong sell signal.
This is another indicator in a series that I'm publishing to fulfill a special request from @ashok1961 so let me know if you ever have any special requests for me.
Leavitt Convolution [CC]The Leavitt Convolution indicator was created by Jay Leavitt (Stocks and Commodities Oct 2019, page 11), who is most well known for creating the Volume-Weighted Average Price indicator. This indicator is very similar to my Leavitt Projection script and I forgot to mention that both of these indicators are actually predictive moving averages. The Leavitt Convolution indicator doubles down on this idea by creating a prediction of the Leavitt Projection which is another prediction for the next bar. Obviously this means that it isn't always correct in its predictions but it does a very good job at predicting big trend changes before they happen. The recommended strategy for how to trade with these indicators is to plot a fast version and a slow version and go long when the fast version crosses over the slow version or to go short when the fast version crosses under the slow version. I have color coded the lines to turn light green for a normal buy signal or dark green for a strong buy signal and light red for a normal sell signal, and dark red for a strong sell signal.
This is another indicator in a series that I'm publishing to fulfill a special request from @ashok1961 so let me know if you ever have any special requests for me.
Ehlers Convolution Indicator [CC]The Convolution Indicator was created by John Ehlers (Cycle Analytics For Traders pgs 170-174) and this is version of an indicator to find potential reversal points. The idea behind this indicator is to use a variation of his AutoCorrelation Indicator that transforms the data using digital signal processing and as you can see it looks very similar to his BandPass Filter . The idea is that when this indicator peaks then it has reached a potential reversal point and so the stock may continue in the current direction but most of the time this indicator correctly points out the reversal points. I have included normal buy and sell signals but generally speaking you would want to buy when the indicator is around 0.05 to 0.10 and moving up and sell when it reaches its peak and is starting to move down.
Let me know if you have any other scripts you would like to see me publish!
Moving RegressionMoving Regression is a generalization of moving average and polynomial regression.
The procedure approximates a specified number of prior data points with a polynomial function of a user-defined degree. Then, polynomial interpolation of the last data point is used to construct a Moving Regression time series.
Application:
Moving Regression allows one to smooth noise on the analyzed chart, assess momentum, confirm trends, and establish areas of support and resistance.
In addition, it can be used as a simple stand-alone forecasting method to identify trend direction and trend reversal points. When the local polynomial is predicted to move up in the next time step, the color of the Moving Regression curve will be green. Otherwise, the color of the curve is red. This function is (de)activated using the Predict Trend Direction flag.
Selecting the model parameters:
The effects of the moving window Length and the Local Polynomial Degree are confounded. This allows for finding the optimal trade-off between noise (variance) and lag (bias). Higher Length and lower Polynomial Degree (such as 1, i.e. linear), will result in "smoother" time series but at the cost of greater lag. Increasing the Polynomial Degree to, for example, 2 (squared) while maintaining the Length will diminish the lag and thus compromise the noise-lag tradeoff.
Relation to other methods:
When the degree of the local polynomial is set to 0 (i.e., fitting data to a constant level), the Moving Regression time series exactly matches the Simple Moving Average of the same length.
[blackcat] L2 Ehlers Convolution IndicatorLevel: 2
Background
John F. Ehlers introduced Convolution Indicator in his "Cycle Analytics for Traders" chapter 13 on 2013.
Function
Since high correlation exists only at the market turning point, the convolution indicator is dependent on the lookback period used in the calculation. Assuming the two price segments have an equal time duration, the peak correlation occurs at half the lookback period of the indicator. For example, if a 13-bar period is used, the market peak would appear with a 7-bar delay. The same market peak would appear with a 19-bar delay if a 39-bar lookback period were used in the convolution computation.
Key Signal
Convolution --> Convolution array
Pros and Cons
100% John F. Ehlers definition translation of original work, even variable names are the same. This help readers who would like to use pine to read his book. If you had read his works, then you will be quite familiar with my code style.
Remarks
The 56th script for Blackcat1402 John F. Ehlers Week publication.
Courtesy of @RicardoSantos for RGB functions.
Readme
In real life, I am a prolific inventor. I have successfully applied for more than 60 international and regional patents in the past 12 years. But in the past two years or so, I have tried to transfer my creativity to the development of trading strategies. Tradingview is the ideal platform for me. I am selecting and contributing some of the hundreds of scripts to publish in Tradingview community. Welcome everyone to interact with me to discuss these interesting pine scripts.
The scripts posted are categorized into 5 levels according to my efforts or manhours put into these works.
Level 1 : interesting script snippets or distinctive improvement from classic indicators or strategy. Level 1 scripts can usually appear in more complex indicators as a function module or element.
Level 2 : composite indicator/strategy. By selecting or combining several independent or dependent functions or sub indicators in proper way, the composite script exhibits a resonance phenomenon which can filter out noise or fake trading signal to enhance trading confidence level.
Level 3 : comprehensive indicator/strategy. They are simple trading systems based on my strategies. They are commonly containing several or all of entry signal, close signal, stop loss, take profit, re-entry, risk management, and position sizing techniques. Even some interesting fundamental and mass psychological aspects are incorporated.
Level 4 : script snippets or functions that do not disclose source code. Interesting element that can reveal market laws and work as raw material for indicators and strategies. If you find Level 1~2 scripts are helpful, Level 4 is a private version that took me far more efforts to develop.
Level 5 : indicator/strategy that do not disclose source code. private version of Level 3 script with my accumulated script processing skills or a large number of custom functions. I had a private function library built in past two years. Level 5 scripts use many of them to achieve private trading strategy.
Leavitt Convolution & Acceleration by CryptorhythmsLeavitt Projection, Convolution, & Acceleration by Cryptorhythms
Intro
Bringing you another open source Gem this time from the January 2020 Issue of TASC.
Description
In the article in the Oct 2019 TASC issue titled "An interplanetary marriage" author Jay Leavitt describes the evolution process required in strategy design by introducing his Mars strategy. This grew out of concepts presented in his earlier TASC articles such as the stratosphere, moon rocket, and tech emini strategies. This dual indicator uses a linear regression of price data to help derive slope and acceleration information, in turn helping him to identify trends and trend turning points.
Additions
As usual a few useful extras are included such as a rudimentary signaling system, bar coloration by trade state, overbought/oversold areas to assist in algorithmic setups, and more!
👍 We hope you enjoyed this indicator and find it useful! We post free crypto analysis, strategies and indicators regularly. This is our 71st script on Tradingview!
💬Check my Signature for other information
Leavitt Convolutions Multicator - Jay Leavitt, Ph.D.Hot off the press, I present this next generation "Leavitt Convolutions Multicator" employing PSv4.0, originally formulated by Jay Leavitt, Ph.D. for TASC - January 2020 Traders Tips. Basically it's an all-in-one combination of three Leavitt indicators. This triplet indicator, being less than a 60 line implementation at initial release, is a heavily modified version of the original indicator using novel techniques, surpassing Leavitt's original intended design.
Utilizing the "Power of Pine", I included the maximum amount of features I could surmise in an ultra small yet powerful package. Configurations are displayed above in multiple scenarios that should be suitable for most traders.
Features List Includes:
Dark Background - Easily disabled in indicator Settings->Style for "Light" charts or with Pine commenting
AND much, much more... You have the source!
For those of you who are new to Pine Script, this script may also help you understand advanced programming techniques in Pine and how they may be utilized in a most effective manner. Most notably, the script shows how to potentially combine three indicators in one with Pine. This is commonly what my dense intricate code looks like behind the veil, and if you are wondering why there is no notes, that's because the notation is in the variable naming.
The comments section below is solely just for commenting and other remarks, ideas, compliments, etc... regarding only this indicator, not others. When available time provides itself, I will consider your inquiries, thoughts, and concepts presented below in the comments section, should you have any questions or comments regarding this indicator. When my indicators achieve more prevalent use by TV members, I may implement more ideas when they present themselves as worthy additions. As always, "Like" it if you simply just like it with a proper thumbs up, and also return to my scripts list occasionally for additional postings. Have a profitable future everyone!
Modulate 40 SymbolsModulates (multiplies) 40 securities
Useful for assessing breadth
Defaults with the Top 40 holdings in SPX
Change symbols to measure breadth in an ETF