OPEN-SOURCE SCRIPT

Tribute to David Paul

I made this indicator as a tribute to the late David Paul.
He mentioned quite a lot about 89 periods moving average (especially on 4h), also the 21 and 55.

I put up some entries when three ma are crossed by price in the same direction, bull/bear backgrounds and a color code for candles because who doesn't love the feeling of a lasting trend.


To be more specific :

The indicator plots sma21, sma55, sma89 and AMA = (sma21+sma55+sma89)/3

When the closing price crosses the highest of the 3 sma, it is considered a bullish confirmation.
At this moment two lines appear, one on the bottom of the candle that crossed, one on the crossing point.
The lowest line can be used as the stop loss value of a long.
The highest line can be used as an entry point for a long.

When the closing price crosses the lowest of the 3 sma, it is considered a bearish confirmation.
At this moment two lines appear, one on the top of the candle that crossed, one on the crossing point.
The highest line can be used as the stop loss value of a short.
The lowest line can be used as an entry point for shorts.

When the closing price is above AMA, it is considered a bullish confirmation.
At this time a blue background appears at the crossing point.
The highest line can be used as the stop loss value for a long.
The starting point of the background can be used as the entry point for a long.

When the closing price is below AMA, it is considered a bearish confirmation.
At this time a red background appears at the crossing point.
The highest line can be used as the stop loss value for a short.
The starting point of the background can be used as the entry point for a short.

When the price is above 3 sma the candles turn blue. Signifying an upward trend.
When the price is below 3 sma the candles turn red. Signifying a bearish trend.
When the price is neither simultaneously above nor below the 3 sma, the candles are gray and the background linked to AMA becomes less vivid. Meaning a loss of vitality of the current trend or an absence of a clear trend.

Ideally, you should take a position towards "Real Long/Short Entry", set your stop loss towards "Ideal Long/Short Entry", and close the trade either when the background ends (riskier but more potential), or when the candles become gray (more conservative but noisier).

In the inputs, you can modify the display rules (explained in the tooltips), by default everything is displayed.
21sma55sma89smadavidpaulentriesoverlaySimple Moving Average (SMA)stoplossTrend Analysis

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer