OrcChieftain

Underworld Hunter Backtesting Algorhitm

This strategy is built to prove the profitability of my Underworld Hunter indicator. It tests two different strategies. I won't be going into the calculation again since it is part of the original script. I just made a few adjustments.

First one is clearly visual. It plots slimmer twin-coloured lines now and has a different colour for every extreme level. Second is less obvious - I switched Relative Strength Index for Commodity Channel Index.

Extreme levels are as follows: green 100 -► 120, yellow 120 -► 140, orange 140 -► 160, red 160 -► 180 and purple above 180, I will have a special separate algorithm for testing optimal CCI levels someday, in this script, these values are only meant to help you with manual operations and do not influence results of the strategy in any way.

#Trending strategy

The trending strategy opens a position whenever the price leaves the bands and holds it until two consecutive bars are closed within the bands. The picture shows one winning position that hasn't yet been resulted. It also shows a few fakeouts. For this strategy, you want to keep the length below 110, the deviation should be below 2 and you probably want to play lower timeframes.


#Within the bands

The second strategy is pretty much the opposite. It opens a position when the price reaches outer bands and holds it until two consecutive bars are closed within the bands and current bar closes below previous bars low in case of long. It is working on hourly timeframes and you need higher length and deviation to succeed. The picture shows a few positions on EURUSD. Each of them is profitable but would be much higher if you closed it manually when it was time. You need to enable this strategy, which automatically disables the other one.


When using my script, you need to bear in mind that the first strategy doesn't detect optimal levels to close the price. A trend is often followed by a less volatile and boring correction which causes bands to shrink and lower your profits if you don't close manually as it will take longer till bands are reached.

On the other hand, second script literally has no stop-loss. As long as the price is outside the range, it will never close which will cause major drawdowns, unless you control the trade manually. CCI is here to help you with both.

I also recommend combining this with Market Profile (on TW, there is only Volume Profile, which can be used in a similar way) and trading day theory (trending with multiple distributions, trending day, normal day, a variation on a normal day, non-trending day or neutral day). Always keep in mind that it is up to traders to be profitable, indicators can support a good trader, but they will not fix a bad one.




오픈 소스 스크립트

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

면책사항

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

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