racer8

ATR Pivot Point Index [racer8]

racer8 업데이트됨   
Description:

ATR Pivot Point Index (ATR_PPI) is based on the theory of mean reversion.
I was inspired to create this indicator after watching a particular YouTube video on the UKspreadbetting channel.
In this video, the trader being interviewed mentioned that he would exit when price is too far from the moving average.
In other words, he exits when he thinks price will revert back to the moving average (mean reversion).
I'm not sure what period moving average he used, so I set it to the standard 14 periods.

I wanted to quantify his strategy so that the user can consistently exit a trade at a fixed distance away from the moving average.
For this indicator, this distance is in ATR units.
This strategy of exiting is known as the mean reversion exit strategy.
Alternatively, if the user wishes to, this indicator can also be used as an entry indicator (Trend entry strategy).
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Parameters:
1. Sma Period - controls length of moving average (Affects histogram).
2. Atr Period - controls length of Atr, doesn't have much affect on indicator (Affects histogram).
3. Atr Pivot Point Level - controls horizontal line, it determines how far away in Atr units you want to exit/enter from the sma for every trade.
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Interpreting signals:

(Trend entry strategy) When histogram is...
Green - enter long
Red - enter short
Purple - No signal

(Mean reversion exit strategy) When histogram is...
Green - exit long
Red - exit short
Purple - No signal
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Calculation:
Distance = Absolute value of (current close - moving average(14))
ATR_units = Distance / ATR(14) ...........Plot as histogram.
Add horizontal line set at (2)*ATR .......Plot line.
Is histogram > line?
Yes, histogram color is green/red.
No, histogram color is purple.

Note: For mean reversion exit strategy, I recommend HIGHER Atr Pivot Point Level values. Vice versa for trend entry strategy.
Enjoy :)
릴리즈 노트:
Minor fix of code.
릴리즈 노트:
...
Changed ATR Pivot Point Level to a default value of 1 instead of 2.
Changed consolidation color from purple to gray :D
릴리즈 노트:
>>>
- Changed consolidation color to indigo. Indigo is a rich color between blue and violet on the visible spectrum, it's a dark purplish blue.
- "ATR pivot point level" is now called "ATR level".
릴리즈 노트:
>>>
Added a simple moving average for the histogram.
릴리즈 노트:
>>>
Added option to show baseline (moving avg of histogram).
릴리즈 노트:
Added bar colors.
릴리즈 노트:
All values are now to 2 decimal places.
오픈 소스 스크립트

이 스크립트의 오써는 참된 트레이딩뷰의 스피릿으로 이 스크립트를 오픈소스로 퍼블리쉬하여 트레이더들로 하여금 이해 및 검증할 수 있도록 하였습니다. 오써를 응원합니다! 스크립트를 무료로 쓸 수 있지만, 다른 퍼블리케이션에서 이 코드를 재사용하는 것은 하우스룰을 따릅니다. 님은 즐겨찾기로 이 스크립트를 차트에서 쓸 수 있습니다.

면책사항

이 정보와 게시물은 TradingView에서 제공하거나 보증하는 금융, 투자, 거래 또는 기타 유형의 조언이나 권고 사항을 의미하거나 구성하지 않습니다. 자세한 내용은 이용 약관을 참고하세요.

차트에 이 스크립트를 사용하시겠습니까?