gary_trades

ADX_TSI_Bol Band Trend Chaser

The idea of this script is to be a low risk strategy on trending stocks (or any other trending market), aiming to achieve minimal draw down (e.g. at time of writing AAPL only had ~1.36% draw down, FB ~1.93% draw down and the SPY was 0.80% draw down and all remained profitable).
Testing proved it shouldn't be used in choppy stocks and best period was on daily charts. The back test filter goes back until 2010 so you can obtain 10 years of data.
The strategy utilizes the 200 Moving Average, a Custom Bollinger Band, a TSI with 52 period weighted moving average and ADX strength.
Although back test dates are set to 2010 - 2020, all other filters (moving average, ADX, TSI , Bollinger Band) are not locked so they can be user amended if desired. However the current settings have been tested with manual trading for quite some time to get this combination correct.
Buy signal is given when trading above the 200 moving average + 5 candles have closed above the upper custom Bollinger + the TSI is positive + ADX is above 20.
As back testing proved that this traded better only in tends then some Sell/Short conditions have been removed from the script and this only takes Long orders.
Only requires 2 additional lines of code to add shorting order and then remove the "buy" condition and this could be used for a downward trending stock instead.
Close for either long or short trades is signaled once the TSI crosses in the opposite direction indicating change in trend strength.
Further optimization could be achieved by adding a stop loss, which I may do in the future.

NOTE: This only shows the lower indicators however for visualization you can use my script "CUSTOM BOLLINGER WITH SMA", which is the upper indicators in this strategy.
This is my first attempt at coding a strategy so I'm happy to receive any feedback or hints on how this could be written better from any experienced coders!
AAPL SPY
สคริปต์โอเพนซอร์ซ

ด้วยจิตวิญญาณของ TradingView อย่างแท้จริง ผู้เขียนสคริปต์นี้ได้เผยแพร่เป็นโอเพนซอร์ส เพื่อให้ผู้ค้าสามารถเข้าใจและตรวจสอบได้ ไชโยให้กับผู้เขียน! คุณสามารถใช้ได้ฟรี แต่การใช้รหัสนี้ซ้ำในสิ่งพิมพ์อยู่ภายใต้กฎระเบียบการใช้งาน คุณสามารถตั้งเป็นรายการโปรดเพื่อใช้บนชาร์ตได้

คำจำกัดสิทธิ์ความรับผิดชอบ

ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ เงื่อนไขการใช้บริการ

ต้องการที่จะใช้สคริปต์นี้บนชาร์ตใช่ไหม?