OPEN-SOURCE SCRIPT
Güncellendi Smart S/R Breakout Signals PX

Smart S/R Breakout Signals
This a dynamic support/resistance breakout system that automatically plots evolving S/R lines from swing highs and swing lows, then signals a trade when price breaks through the opposite zone with confirmation.
How it works
The script tracks the lowest low (for Buy mode) or highest high (for Sell mode) and waits for a configurable number of consecutive closes (Num) above/below the prior bar's range before "fixing" that level as a support or resistance line.
Once a level is fixed, the script searches for the most significant opposing swing point and draws an S/R line from it.
When price closes through that opposing line, a new support/resistance cycle begins. After a chosen number of these S/R flips (Buyafter), the script arms itself to look for an entry.
An entry triggers on the breakout candle, plotting:
Entry label at the breakout level
Stop Loss — either the most recent S/R line or the last confirmed swing point (SL Mode)
Take Profit — calculated using your risk/reward multiple (rw)
Trade outcome is tracked live: TP/SL labels update with ✅ (hit), ❌ (missed), or 💔 (stopped out) so you can visually audit every signal on the chart.
A built-in fail-safe (Stop After X Fail) pauses new signals after a set number of consecutive losing trades, helping avoid chasing a choppy market.
This a dynamic support/resistance breakout system that automatically plots evolving S/R lines from swing highs and swing lows, then signals a trade when price breaks through the opposite zone with confirmation.
How it works
The script tracks the lowest low (for Buy mode) or highest high (for Sell mode) and waits for a configurable number of consecutive closes (Num) above/below the prior bar's range before "fixing" that level as a support or resistance line.
Once a level is fixed, the script searches for the most significant opposing swing point and draws an S/R line from it.
When price closes through that opposing line, a new support/resistance cycle begins. After a chosen number of these S/R flips (Buyafter), the script arms itself to look for an entry.
An entry triggers on the breakout candle, plotting:
Entry label at the breakout level
Stop Loss — either the most recent S/R line or the last confirmed swing point (SL Mode)
Take Profit — calculated using your risk/reward multiple (rw)
Trade outcome is tracked live: TP/SL labels update with ✅ (hit), ❌ (missed), or 💔 (stopped out) so you can visually audit every signal on the chart.
A built-in fail-safe (Stop After X Fail) pauses new signals after a set number of consecutive losing trades, helping avoid chasing a choppy market.
Sürüm Notları
Tp line extend until candle which touched itimproved name of inputs in panel
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuyla, bu komut dosyasının mimarı, yatırımcıların işlevselliğini inceleyip doğrulayabilmesi için onu açık kaynaklı hale getirdi. Yazarı tebrik ederiz! Ücretsiz olarak kullanabilseniz de, kodu yeniden yayınlamanın Topluluk Kurallarımıza tabi olduğunu unutmayın.
ChartTrader-X
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, alım satım veya diğer türden tavsiye veya öneriler anlamına gelmez ve teşkil etmez. Kullanım Koşulları bölümünde daha fazlasını okuyun.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuyla, bu komut dosyasının mimarı, yatırımcıların işlevselliğini inceleyip doğrulayabilmesi için onu açık kaynaklı hale getirdi. Yazarı tebrik ederiz! Ücretsiz olarak kullanabilseniz de, kodu yeniden yayınlamanın Topluluk Kurallarımıza tabi olduğunu unutmayın.
ChartTrader-X
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, alım satım veya diğer türden tavsiye veya öneriler anlamına gelmez ve teşkil etmez. Kullanım Koşulları bölümünde daha fazlasını okuyun.