ZigZag++Hey Awesome Traders
I noticed people were so happy with my ZigZag lucemanb script and so I made one that is more user-friendly and customizable
Please note the original one is dedicated to developers, The code is very minimal for fast understanding when anyone wants to use it in their development
In this script, I have included several features like multi-timeframe and alerts. Do take a look and enjoy
If you are using the indicator, please comment down the link to your script
If you would love to support my work through donations, Am so happy to receive them
ADDITIONAL FEATURES
Do u have an idea or a feature that you want to be added,
You can ping me or ask about it here, I can always update
Check out some of the best works i have done with this script
1. Angle trading
2. Harmonic Patterns
Trend
B3 Clear Method Streak CountAbout Clear Method -- to repeat my prior post on the bar painter script:
This indicator is translated out of Technical Analysis of Stocks & Commodities , September 2010, (I take zero design credit). The script simply looks for the price action to break or "clear" the most recent action, and only changes the paintbar color if the action indeed clears the previous candles. Simple to use, just add to your chart from your favorites and change the colors in the UI. It does the rest.
This version can replace my previous Clear Method Bar Painter as it also paints the bars.
What is different is this share is a lower study that counts the streak of the bars shown via histogram.
The way to use the streak is to notice the previous streaks and get a sense of how long the current trend is lasting versus prior trends of the same direction.
@Tradestation recently posted their "price streak" study, and this one is quite similar in nature.
Enjoy, the code open to view,
_B3
d^.^b
Trend Balance Point System by Welles WilderThis is the original Trend Balance Point System created by Welles Wilders in 1978, rules can be found in his book New Concepts in Technical Trading Systems.
Trend TrailingAndrew Abraham
It can be used as:
- stop loss indicator
- indicator of support and resistance
- buy and sell signals
Point and Figure (PnF) Moving Averages HistogramThis is live and non-repainting Point and Figure Chart Moving Average Histogram tool. The script has it’s own P&F engine and not using integrated function of Trading View.
Point and Figure method is over 150 years old. It consist of columns that represent filtered price movements. Time is not a factor on P&F chart but as you can see with this script P&F chart created on time chart.
P&F chart provide several advantages, some of them are filtering insignificant price movements and noise, focusing on important price movements and making support/resistance levels much easier to identify.
Moving averages on Point & Figure charts are based on the average price of each column while bar chart moving averages are based closing price. Average Price means (ClosePrice + OpenPrice) / 2.
Because of there is double smoothing, you should use shorter lengths for moving averages. Double smoothing means: using average price smooths once, using length greater than 2 smooths price second time.
If you are new to Point & Figure Chart then you better get some information about it before using this tool. There are very good web sites and books. Please PM me if you need help about resources.
Options in the Script
Box size is one of the most important part of Point and Figure Charting. Chart price movement sensitivity is determined by the Point and Figure scale. Large box sizes see little movement across a specific price region, small box sizes see greater price movement on P&F chart. There are four different box scaling with this tool: Traditional, Percentage, Dynamic (ATR), or User-Defined
4 different methods for Box size can be used in this tool.
User Defined: The box size is set by user. A larger box size will result in more filtered price movements and fewer reversals. A smaller box size will result in less filtered price movements and more reversals.
ATR: Box size is dynamically calculated by using ATR, default period is 20.
Percentage: uses box sizes that are a fixed percentage of the stock's price. If percentage is 1 and stock’s price is $100 then box size will be $1
Traditional: uses a predefined table of price ranges to determine what the box size should be.
Price Range Box Size
Under 0.25 0.0625
0.25 to 1.00 0.125
1.00 to 5.00 0.25
5.00 to 20.00 0.50
20.00 to 100 1.0
100 to 200 2.0
200 to 500 4.0
500 to 1000 5.0
1000 to 25000 50.0
25000 and up 500.0
Default value is “ATR”, you may use one of these scaling method that suits your trading strategy.
If ATR or Percentage is chosen then there is rounding algorithm according to mintick value of the security. For example if mintick value is 0.001 and box size (ATR/Percentage) is 0.00124 then box size becomes 0.001.
And also while using dynamic box size (ATR or Percentage), box size changes only when closing price changed.
Reversal : It is the number of boxes required to change from a column of Xs to a column of Os or from a column of Os to a column of Xs. Default value is 3 (most used). For example if you choose reversal = 2 then you get the chart similar to Renko chart.
Source: Closing price or High-Low prices can be chosen as data source for P&F charting.
Options for P&F Bollinger Bands:
MA Type: MA type can be EMA or SMA
MA Source: Moving averages on P&F charts are based on the average price of each column. Bar chart moving averages are based on each close price. Average price means “(ClosePrice + OpenPrice) / 2”. You can choose Close Price or Average Price as source. Default is Average Price.
Fast MA Length : Length of Fast Moving average, shorter length than Slow MA
Slow MA Length : Length of Slow Moving average, greater length than Slow MA
There are alerts when Fast MA Crossed over/under Slow MA conditions. While adding alert “Once Per Bar Close” option should be chosen.
Growing or Waning Patterns [Alerts]Example how to color patterns of 3 bodies growing or waning by percentage with or without trend. Also included option for alert triggers. The yellow triangles on the chart denote where the alert triggers will fire.
• Choose Pattern Of Filter: shows bodies growing or waning or both.
• Sample Lengths Of AvgBar: number of recent bars to use for average size.
• BigBar Is Min% Of AvgBar: the minimum percent of average the big bar must be.
• MedBar Is Max% Of BigBar: the maximum percent of big bar the medium bar can be.
• SmlBar Is Max% Of MedBar: the maximum percent of medium bar the small bar can be.
• Repeat Pattern If n Bars: the number of bars to ignore repeat patterns, 1 allows all.
• Trending: on requires the growing or waning patterns to also be trending.
• GrayBars: colors non pattern bodies gray.
NOTICE: This is an example script and not meant to be used as an actual strategy. By using this script or any portion thereof, you acknowledge that you have read and understood that this is for research purposes only and I am not responsible for any financial losses you may incur by using this script!
Rivanews Setup - Riva-Keltner, Média Rock [xdecow]This setup was created by Rivadavila S. Malheiros
There are 2 Keltner Channels with exponential moving averages of 21 (riva) and 89 (rock) and ATR multiplier of 0.618.
When the price is between the bands, it is a sign of consolidation (yellow).
When the price is above the bands, it is an upward trend (green).
When the price is below the bands, it is a downward trend (red).
When the price crosses rock 89 and closes up / down, it may be a sign of a reversal. But it has a high probability of testing rock 89 again.
------------------------------------------------------------------------------------------
PT-BR
Este setup foi criado por Rivadavila S. Malheiros
São 2 Keltner Channels com médias móveis exponenciais de 21 (riva) e 89 (rock) e multiplicador do ATR de 0.618.
Quando o preço está entre as bandas, é sinal de consolidação (amarelo).
Quando o preço está acima das bandas, é uma tendencia de alta (verde).
Quando o preço está abaixo das bandas, é uma tendencia de baixa (vermelho).
Quando o preço cruza a rock 89 e fecha acima/abaixo, pode ser sinal de reversão. Mas tem uma alta probabilidade de testar a rock 89 novamente.
BERLIN Renegade - Entry and ExitThis is the entry and exit part of a larger algorithm called the "BERLIN Renegade". It is based on the NNFX way of trading, with some modifications.
For entry, it consists of Modified Chaikin Oscillator and Advanced MACD. The Advanced MACD is not available on its own, but all others are publically
available.
For exit it consists of the DIDI Index and the QQE line (original idea by Jie). Special thanks to Michael Kuczynski for the idea to include the FTLM digital filter.
Long signal: Green bars (upper and lower are both green)
Short signal: Red bars (upper and lower are both red)
Exit signal: Purple bars (bottom) - DIDI Index with QQE line
Grover Llorens Activator Strategy AnalysisThe Grover Llorens Activator is a trailing stop indicator deeply inspired by the parabolic SAR indicator, and aim to provide early exit points and reversal detection. The indicator was posted not so long ago, you can find it here :
Today a strategy using the indicator is proposed, and its profitability is analyzed on 3 different markets with the main time frame being 1 hour, remember that lower time frames involve lower absolute price changes, therefore we are way more affected by the spread, and we can require a larger position sizing depending on our investment target, trading higher time-frames is always a good practice and this is why 1 hour is selected. Based on the result we might make various conclusions regarding the indicator accuracy and might have ideas on future improvements of the indicator.
I'am not great when it comes to strategy design, i still hope to share correct and useful information in this post, let me know your thoughts on the post format and if i should make more of these.
Setup And Rules
The analysis is solely based on the indicator signals, money management isn't taken into account, this allow us to have an idea on the indicator robustness and resilience, particularly on extremely volatile markets and ones exhibiting a chaotic structure, altho it is normally good practice to close any position before a market closure in order to avoid any potential major gaps.
The settings used are 480 for length and 14 for mult, this create relatively mid term signals that are suited for a trend indicator such as the Grover Llorens Activator, unfortunately we can't infer the indicator optimal settings, thats how it is with any technical indicator anyway.
Here are the rules of our strategy :
long : closing price cross over the indicator
short : closing price cross under the indicator
We use constant position sizing, once a signal is triggered all the previous positions are closed.
Description Of The Statistics Used
Various statistics are presented in this post, here is a brief description of the main ones :
Percent Profitability (higher = better): Percentage of winning trades, that is : winning trades/total number of trades × 100
Maximum Drawdown (lower = better) : The highest difference between a peak and a valley in the balance, that is : peak - valley , in percentage : (peak - valley)/peak × 100
Profit Factor (higher = better) : Gross profit divided by gross loss, values under 1 represent gross losses superior to the gross profits
Remember that more volatility = more risk, since higher absolute price changes can logically cause larger losses.
EURUSD
The first market analyzed is the Forex market with the EURUSD major pair with a position sizing of 1000 units (1 micro lot). Since October EURUSD is not showing any particular strong trend but posses a discrete rising motion, fortunately cycles can be observed.
The equity was rising until two trades appeared causing a decline in the equity. Before October a bearish market could be observed.
We can see that the equity is rising, the trend still posses various retracements that affect our indicator, however we can see that the indicator totally nail the end of the trend, thats the power of converging toward the price.
In short :
$ 86.63 net profit
340 closed trades
37.65 % profitable (thats a lot of loosing trades)
1.19 profit factor
$ 76.67 max drawdown
Applying a spread would create negative results (in general the average spread is used), not a great start...
BTCUSD
The cryptocurrency market is relatively more volatile than others, which also mean potentially higher returns, we test the indicator using certainly the most traded cryptocurrency, BTCUSD. We will use a position sizing of 1 unit.
In the case of BTCUSD the strategy balance is relatively stationary around the initial capital, with of course high dispersion.
from september to december the market is bearish with various ranging periods, no apparent cycles can be observed, except maybe in the ranging period of october, this ranging period is followed by a non linear trend (relatively parabolic) that the indicator failed to capture in its integrity (this is a recurrent problem and it is starting to piss me off xD).
In short :
$ 2010.64 net profit (aka how i bet the crypto market)
395 closed trades
38.23 % profitable
1.036 profit factor
$ 5738.01 max drawdown (aka how i lost to the crypto market)
AMD
AMD stand for Advanced Micro Devices and is a company focused on the development of computer technology, i love the microprocessor market and i really like AMD who start this year in a pretty great way with a net bullish trend.
The performance of the indicator on AMD is decent (at last !) with the equity producing many new higher highs. The indicator performance still drop in the middle end of 2019 with a large equity drawdown of 17$ caused by the gap of august 8. Unfortunately AMD, like lot of well behaving stocks can only tells us that the indicator has good performances on heavily trending markets with no excess of noise or chaotic structures.
In short :
$ 17.86 net profit (Enough for a consistent lunch)
295 closed trades
36.27 % profitable
1.414 profit factor
$ 10.37 max drawdown.
Conclusion
A strategy using the recently proposed Grover Llorens activator has been presented. We can easily conclude that the indicator can't possibly generate long term returns under chaotic and volatile markets, and could even produce unnecessary trades in trending markets without much parasitic fluctuations such as noise and retracements (think about a simple linear trend) since the indicator converge toward the price and would therefore automatically cross over/under the trend, thus guaranteeing a false signal.
However we have seen its ability to provide accurate early reversal detection shine from time to time, thus over performing lagging indicators in this aspect, however the duration of price fluctuations isn't fixed at a certain period, the rate of convergence should be way faster during volatile fluctuations, of moderate speed during more cyclic fluctuations, and really slow with apparent long term trends, this could be achieved by making the indicator adaptive, but it won't really make it necessarily perform better.
That said i still believe that converging trend indicators are really interesting and aim to capture the non lasting behavior of price fluctuations, they shouldn't receive so much hate (think about the poor p-sar).
Thanks for reading !
Waddah Attar Explosion MTFAll I did here is add multi timeframe function to the Waddah Attar indicator, as I couldn't find it in the TradingView library.
A description of the original post by Lazy Bear
UT Bot Strategy with Backtesting Range [QuantNomad]UT Bot indicator was inially developer by @Yo_adriiiiaan
Idea of original code belongs @HPotter
I can't update my original UT Bot Strategy so I publishing new strategy with backtesting range included.
I just took code of Yo_adriiiiaan, cleaned it, deleted all useless pieces of code, transformet to v4 and created a strategy from it.
Also I added an input that allows you to swich to signals from Heiking Ashi. I saw that author uses HA for the indicator and on HA it look much nices then on real candles.
Do not add this strategy to HA candles, use usual candles and this checkbox.
Original script:
UT Bot
Grover Llorens Activator [alexgrover & Lucía Llorens] Trailing stops play a key role in technical analysis and are extremely popular trend following indicators. Their main strength lie in their ability to minimize whipsaws while conserving a decent reactivity, the most popular ones include the Supertrend, Parabolic SAR and Gann Hilo activator. However, and like many indicators, most trailing stops assume an infinitely long trend, which penalize their ability to provide early exit points, this isn't the case of the parabolic SAR who take this into account and thus converge toward the price at an increasing speed the longer a trend last.
Today a similar indicator is proposed. From an original idea of alexgrover & Lucía Llorens who wanted to revisit the classic parabolic SAR indicator, the Llorens activator aim to converge toward the price the longer a trend persist, thus allowing for potential early and accurate exit points. The code make use of the idea behind the price curve channel that you can find here :
I tried to make the code as concise as possible.
The Indicator
The indicator posses 2 user settings, length and mult , length control the rate of convergence of the indicator, with higher values of length making the indicator output converge more slowly toward the price. Mult is also related with the rate of convergence, basically once the price cross the trailing stop its value will become equal to the previous trailing stop value plus/minus mult*atr depending on the previous trailing stop value, therefore higher values of mult will require more time for the trailing stop to reach the closing price, use higher values of mult if you want to avoid potential whipsaws.
Above the indicator with slow convergence time (high length) and low mult.
Points with early exit points are highlighted.
Usage For Oscillators
The difference between the closing price and an overlay indicator can provide an oscillator with characteristics depending on the indicators used for differencing, Lucía Llorens stated that we should find indicators for differencing that highlight the cycles in the price, in other terms : Price - Signal , where we want to find Signal such that we maximize the visibility of the cycles, it can be demonstrated that in the case where the closing price is an additive model : Trend + Cycles + Noise , the zero lag estimation of the Trend component can allow for the conservation of the cycle and noise component, that is : Price - Estimate(Trend) , for example the difference between the price and moving average isn't optimal because of the moving average lag, instead the use of zero lag moving averages is more suitable, however the proposed indicator allow for a surprisingly good representation of the cycles when using differencing.
The normalization of this oscillator (via the RSI) allow to make the peak amplitude of the cycles more constant. Note however that such method can return an output with a sign inverse to the one of the original cycle component.
Conclusion
We proposed an indicator which share the logic of the SAR indicator, that is using convergence toward the price in order to provide early exit points detection. We have seen that this indicator can be used to highlight cycles when used for differencing and i don't exclude publishing more indicators based on this method.
Lucía Llorens has been a great person to work with, and provided enormous feedback and support while i was coding the indicator, this is why i include her in the indicator name as well as copyright notice. I hope we can make more indicators togethers in the future.
(altho i was against using buy/sells labels xD !)
Thanks for reading !
unRekt - KISS CrossKISS Cross is a moving average crossover and is part of the ''keeping it simple' series that have a similar color scheme. With this indicator you can select the moving average you'd like to use either SMA, EMA, WMA, or VWMA. Each moving average can be turned on or off and input changed. The first two MA's will change color on the cross from green to red depending on cross up or a cross down.
unRekt - KISS OBVOBV is the 'On Balance Volume' indicator and is part of the 'keeping it simple' series that have a similar color scheme. the OBV measures buying and selling pressure as a cumulative indicator, adding volume on up days and subtracting it on down days. The OBV can show divergences or confirm trend.
unRekt - KISS MacdieMacdie is the MACD 'Moving Average Convergence Divergence' indicator and is part of the 'keeping it simple' series that have a similar color scheme. MACD is based on the difference between two moving averages calculated for different periods, typically 12 and 26. The MACD can show trend and strength of an asset while also showing Divergences.
unRekt - KISS StochieStochie is the StochRSI indicator and is part of the ''keeping it simple' series that have a similar color scheme. The Stochastic RSI technical indicator applies the Stochastic Oscillator to values of the Relative Strength Index (RSI). The indicator thus produces two main plots FullK and FullD oscillating between oversold and overbought levels. The StochRSI can also be used to detect divergence and trend.
unRekt - KISS MarsieMarsie is an EMA-RSI indicator and part of the 'keeping it simple' series that have a similar color scheme. The RSI 'Relative Strength Index' is a momentum oscillator, measuring the velocity and magnitude of directional price movements. it is measured from 0 - 100 with 30 and 70 being low "oversold" and high "overbought" conditions. It is also commonly used to determine bullish or bearish divergences.
The EMA aspect is the 'Exponential Moving Average' which has had the RSI calculation added to it and acts a signal line when the RSI crosses it for buy and sell opportunities.
TrendFlex Oscillator - Dr. John EhlersHot off the press, I present this NEW "TrendFlex Oscillator" employing PSv4.0, originally formulated by Dr. John Ehlers for TASC - February 2020 Traders Tips. John Ehlers might describe it's novel characteristics as being a reversal sensitive near zero-lag averaging indicator retaining the TREND component. Also, I would add that irregardless of the sampling interval, this indicator has a bound range between +/-2.0 on "1 second" candles all the way up to "1 month" candle durations. This indicator also has a companion indicator entitled "Reflex Oscillator". I have published it in tandem with this one in my scripts profile.
One notable difference between this and the original formulation is that I have added an independent control for the Super Smoother. This "tweak" is enabled by applying the override and adjusting it's period. There is a "Post Smooth" input() that "tweaks" the internal TrendFlex EMA too. Keep in mind that my intention of adding tweaks is solely for experimentation with the original formulation.
I also added adjustable levels for those of you that may wish to employ alertcondition()s to this indicator somehow. Providing a more utilitarian approach, I created this with an easy to use reusable function named trendflex(). As always, I have included advanced Pine programming techniques that conform to proper "Pine Ettiquette". Being this is one of John Ehlers' first two simultaneously released indicators for 2020, I felt a few more bells and whistles were appropriate as a proper contribution to the Tradingview community.
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!
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!
PVT Osc - Price Volume Trend Oscillator [UTS]The oscillator version of the Price Volume Trend indicator (PVT) can be considered as a leading indicator of future price movements. The PVT Indicator is similar to the On Balance Volume indicator as it is also used to measure the strength of a trend.
The difference between the OBV and the PVT is that where the OBV adds all volumes when price achieves higher daily closes and subtracts them when price registers a lower daily close, the PVT adds or subtracts only a portion of the volume from the cumulative total in relation to a percentage change in price.
The general market consensus is that this difference enables the PVT to more accurately represent money flow volumes in and out of a stock or commodity.
The PVT has been designed so that it is capable of forecasting directional changes in price. For instance, if the price of a stock is rising and the PVT begins to fall, then this is indicative that a price reversal could occur very soon.
The general consensus is that the PVT is more accurate at detecting new trading opportunities than the OBV because of the differences in their construction. The OBV is designed so that it adds the same amount of volume whether the price closes upwards by just a small fraction or by multiples of its day opening value. On the other hand, the PVT adds volume proportional to the amount the price closed higher.
General Usage
Plain old PVT can be used to confirm trends, as well as spot possible trading signals due to divergences.
A benefit of the oscillator version is that it can produce LONG or SHORT signals on zero line cross.
Or controversy, disallow LONG trades in bearish territory and disallow SHORT trades in bullish territory.
Moving Averages
4 different Moving Averages are available:
EMA (Exponential Moving Average)
SMA (Simple Moving Average)
VWMA (Volume Weighted Moving Average)
WMA (Weighted Moving Average)
OBV Osc - On Balance Volume Oscillator [UTS]The oscillator version of the well known On Balance Volume Indicator (OBV).
General Usage
Plain old OBV can be used to confirm trends, as well as spot possible trading signals due to divergences.
A benefit of the oscillator version is that it can produce LONG or SHORT signals on zero line cross.
Moving Averages
4 different Moving Averages are available:
EMA (Exponential Moving Average)
SMA (Simple Moving Average)
VWMA (Volume Weighted Moving Average)
WMA (Weighted Moving Average)
[PX] ADX and DI v4Hey guys,
I recently used the "ADX and DI" indicator in a variety of my own scripts. Because I keep on developing version 4 scripts and the "ADX and DI" indicator is developed in one of the previous PineScript versions, I had to update the old script every time I wanted to use it. I decided to publish the updated version and also changed a few things:
- ADX color is now orange
- Instead of plotting the DI+ and DI- lines, it's filling the space between the two (can be changed in the "style"-section)
Maybe some of you find it useful. If so, leave a like or follow :)
Happy trading,
paaax
P.S: The original indicator was developed by the user @MasaNakamura. Thanks for your great work!
Donchian Breakout StrategyThis strategy buys when the Donchian Channel is broken to the upside and uses the lower Donchian Channel line as a trailing stop. You can also choose to use a moving average as a filter to keep you out of trades that are counter trend.
You can also configure which dates you want to backtest, so you can see how this behaves over specific time frames and market cycles.