Craig_Claussen

Strategy - DMI Indicator with DPO Indicator as a Guard

The Directional Movement Index Indicator is one of my favorite indicators in tradingview's built-in library. It is free to use for all
For more information on what the DMI is, please visit: www.tradingview.com/...directionalmovement/
The only problem I've come across with the DMI is that when it hits a 'trade range zone' it triggers false new trends (this is the case with almost every indicator I've ever tested).

This script modifies the DMI by removing the need for the ADX logic. It only focuses on the +DI and the -DI.
In order to remove the 'noise' generated during a trade range zone I have added another powerful indicator called the Detrended Price Oscillator.
The DPO is also a 'built-in' indicator on tradingview. www.tradingview.com/...ndedpriceoscillator/
The DPO is used in conjunction with the DMI to stop trade ranges from wrecking your profits.

This strategy logic simply checks for the DMI indicator to cross itself. If the +DI crosses over the -DI this is a bullish cross and visa versa, if the -DI crosses over the +DI then it could mean bearish sentiment is building.
But then strategy logic uses the DPO to check if the DPO is above 0 or below 0 value

If the +DI crosses over the -DI and the DPO is above 0 value, then it's a Long entry point.
However, if the +DI crosses over the -DI and the DPO is below 0 value, then the Long signal is void.
And visa versa, if the -DI crosses over the +DI and the DPO is below 0 value, then it's a Short entry point (unless the DPO is greater than 0)
With this DPO 'guard' in place, it helps us keep the total trades executed to a minimum.
This is vital to push through trade ranges that can wreck your profit potential.

I wish I could create a better plotting mechanism for this indicator so you can better see the visuals. But combining the DMI to scale with the DPO is not possible.
The best solution is to simply add another DMI indicator to your chart so you can compare the DMI to this script that is dominated by the DPO (yellow line).

Enjoy! Likes are much appreciated!








Mã nguồn mở

Với tinh thần TradingView, tác giả của tập lệnh này đã xuất bản nó dưới dạng mã nguồn mở, vì vậy các nhà giao dịch có thể hiểu và xác minh nó. Chúc mừng tác giả! Bạn có thể sử dụng mã này miễn phí, nhưng việc sử dụng lại mã này trong một ấn phẩm chịu sự điều chỉnh của Nội quy nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Thông báo miễn trừ trách nhiệm

Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?