OPEN-SOURCE SCRIPT
TheStrat Alerts - TPC Edition

## TheStrat Alerts - TPC Edition
Finally, an indicator that monitors and sends alerts for TheStrat candle
combination setups — both as CONFIRMED signals and as EARLY WARNING
(pre-close) heads-up alerts, so you don't have to sit and watch every
ticker and timeframe yourself.
**How does the indicator work?**
The script labels every closed candle as a 1 (inside), 2u/2d (directional),
or 3 (outside) bar based on whether it broke the prior candle's high
and/or low. It then watches for specific sequences of these labels
(actionable setups) and fires an alert using TradingView's built-in
alert system.
**Two alert tiers:**
- Early Warning — fires the moment the precursor bars close, before the
live bar has done anything (e.g. "2-1-?" — watch for a developing 2-1-2)
- Confirmed — fires once the live bar has actually broken the required way
**Setups covered:**
2-1-2 · 3-1-2 · 1-2-2 reversal · 3-2-2 reversal · 2-2 reversal watch ·
Randy Jackson · Pivot Machine Gun (5x consecutive 2s) · Failed 2u/2d ·
1-3 Nirvana · 50% retracement after a 2u/2d
**Full Timeframe Continuity (FTFC):**
Optional filter that only allows directional alerts when Hour/Daily
(and optionally Weekly/Monthly) candles are aligned. 2-1-2 has no
directional bias and is exempt from this filter.
**To enable:**
1. Add the indicator to your ticker/timeframe of choice
2. Open the indicator settings (cog wheel) and toggle which setups
you want alerted on
3. Use TradingView's "Create Alert" feature, set the condition to
one of this indicator's alertconditions, and choose "Once Per Bar"
for Early Warning alerts or "Once Per Bar Close" for Confirmed alerts
*This indicator is not market or timeframe specific — apply it to any
ticker/timeframe combination you trade.*
Finally, an indicator that monitors and sends alerts for TheStrat candle
combination setups — both as CONFIRMED signals and as EARLY WARNING
(pre-close) heads-up alerts, so you don't have to sit and watch every
ticker and timeframe yourself.
**How does the indicator work?**
The script labels every closed candle as a 1 (inside), 2u/2d (directional),
or 3 (outside) bar based on whether it broke the prior candle's high
and/or low. It then watches for specific sequences of these labels
(actionable setups) and fires an alert using TradingView's built-in
alert system.
**Two alert tiers:**
- Early Warning — fires the moment the precursor bars close, before the
live bar has done anything (e.g. "2-1-?" — watch for a developing 2-1-2)
- Confirmed — fires once the live bar has actually broken the required way
**Setups covered:**
2-1-2 · 3-1-2 · 1-2-2 reversal · 3-2-2 reversal · 2-2 reversal watch ·
Randy Jackson · Pivot Machine Gun (5x consecutive 2s) · Failed 2u/2d ·
1-3 Nirvana · 50% retracement after a 2u/2d
**Full Timeframe Continuity (FTFC):**
Optional filter that only allows directional alerts when Hour/Daily
(and optionally Weekly/Monthly) candles are aligned. 2-1-2 has no
directional bias and is exempt from this filter.
**To enable:**
1. Add the indicator to your ticker/timeframe of choice
2. Open the indicator settings (cog wheel) and toggle which setups
you want alerted on
3. Use TradingView's "Create Alert" feature, set the condition to
one of this indicator's alertconditions, and choose "Once Per Bar"
for Early Warning alerts or "Once Per Bar Close" for Confirmed alerts
*This indicator is not market or timeframe specific — apply it to any
ticker/timeframe combination you trade.*
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.