OPEN-SOURCE SCRIPT

Step-Based Trailing Stop-Loss Indicator

151
This indicator is built for momentum traders who want to maximize winning trades and minimize losses through a smart, step-based trailing stop-loss system. Instead of using a fixed Take Profit, this tool dynamically protects profits once the trade reaches a favorable RR (Risk-to-Reward) level.

How It Works:
Manual Entry Input

You enter your Entry Price and select Buy/Sell in the settings.

This flexibility allows backtesting or live trade tracking.

Initial Setup

Default SL: 50 ticks(Tested on us30,but works on any pair you just need to adjust SL)

TP for reference: 4R — can be used for benchmarking, but we don't limit profits with a hard TP.

Trailing Logic

Once price reaches 3R in profit:

The SL begins trailing.

It starts at 2R, keeping a 1R cushion behind the max profit.

For every 0.5R gain, SL also moves up by 0.5R:

Example: At 3.5R → SL is at 2.5R
At 5.0R → SL is at 4.0R

This trailing continues until the SL is hit or the trend exhausts.

Chart Features

🟧 Entry Line

🔴 Initial SL

🟢 Reference TP (4R, optional)

🟣 Dynamic Trailing SL

🏷️ Labels for Entry & SL levels

Penafian

Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.