OPEN-SOURCE SCRIPT
Pullbacks Completo

This indicator is a comprehensive Trend Following toolkit that combines two distinct, high-probability pullback strategies into a single, intelligent interface. It is designed to help traders identify precise entry points during corrections in established trends, filtering out low-quality noise.
The indicator features Smart Conflict Detection: if the two strategies generate opposing signals on the same candle, the system blocks the individual alerts and displays a Purple "X", warning the trader of market indecision.
Strategy 1: Stoch Pullback (Triangles)
Visual: Green/Red Triangles Logic:
Trend: Defined by the alignment of the Fast EMA (21) and Slow EMA (100).
The Setup: The indicator waits for the Stochastic RSI to enter an Overbought or Oversold zone.
Strict Filter: A signal is only valid if, while in the zone, the price physically tests the Fast EMA (closes against it). This filters out "shallow" pullbacks.
Trigger: The signal is fired when the Stochastic RSI crosses back out of the extreme zone, resuming the trend.
Strategy 2: Dave Landry Setup (Dots)
Visual: Green/Red Circles Logic:
Trend: Filtered by MACD Histogram momentum and the relation to the Fast EMA (21).
The Pattern: Looks for a correction of at least 2 candles making lower lows (for uptrends) or higher highs (for downtrends).
Trigger: Enters when the price breaks the high/low of the previous candle, provided it closes in favor of the EMA 21.
Anti-Climax Filter: Includes a "Stretched" filter to prevent buying/selling on exhausted "Elephant Bars" (huge candles that have already consumed the move).
Key Features
Dual Alert System: Receive specific alerts for "Pullback" or "Landry" setups.
Conflict Warning: If Strategy A says "Buy" and Strategy B says "Sell" simultaneously, a "Doubtful Signal" alert is triggered, and a purple Cross appears on the chart.
Smart Visibility: The indicator automatically hides or shows the Moving Averages depending on which strategies you have enabled in the settings.
Educational Tooltips: Hover over the "i" icons in the settings menu to read the rationale behind each specific filter.
How to Use
Green Triangle: Look for Long opportunities (Stoch Pullback).
Green Dot: Look for Long opportunities (Landry Breakout).
Red Triangle: Look for Short opportunities (Stoch Pullback).
Red Dot: Look for Short opportunities (Landry Breakout).
Purple X: Stay Out. The setups are conflicting (Trend vs. Momentum disagreement).
Configuration You can toggle each strategy on/off in the settings menu. You can also choose to display the Overbought/Oversold background zones to visualize where the Stoch Pullback is "arming".
The indicator features Smart Conflict Detection: if the two strategies generate opposing signals on the same candle, the system blocks the individual alerts and displays a Purple "X", warning the trader of market indecision.
Strategy 1: Stoch Pullback (Triangles)
Visual: Green/Red Triangles Logic:
Trend: Defined by the alignment of the Fast EMA (21) and Slow EMA (100).
The Setup: The indicator waits for the Stochastic RSI to enter an Overbought or Oversold zone.
Strict Filter: A signal is only valid if, while in the zone, the price physically tests the Fast EMA (closes against it). This filters out "shallow" pullbacks.
Trigger: The signal is fired when the Stochastic RSI crosses back out of the extreme zone, resuming the trend.
Strategy 2: Dave Landry Setup (Dots)
Visual: Green/Red Circles Logic:
Trend: Filtered by MACD Histogram momentum and the relation to the Fast EMA (21).
The Pattern: Looks for a correction of at least 2 candles making lower lows (for uptrends) or higher highs (for downtrends).
Trigger: Enters when the price breaks the high/low of the previous candle, provided it closes in favor of the EMA 21.
Anti-Climax Filter: Includes a "Stretched" filter to prevent buying/selling on exhausted "Elephant Bars" (huge candles that have already consumed the move).
Key Features
Dual Alert System: Receive specific alerts for "Pullback" or "Landry" setups.
Conflict Warning: If Strategy A says "Buy" and Strategy B says "Sell" simultaneously, a "Doubtful Signal" alert is triggered, and a purple Cross appears on the chart.
Smart Visibility: The indicator automatically hides or shows the Moving Averages depending on which strategies you have enabled in the settings.
Educational Tooltips: Hover over the "i" icons in the settings menu to read the rationale behind each specific filter.
How to Use
Green Triangle: Look for Long opportunities (Stoch Pullback).
Green Dot: Look for Long opportunities (Landry Breakout).
Red Triangle: Look for Short opportunities (Stoch Pullback).
Red Dot: Look for Short opportunities (Landry Breakout).
Purple X: Stay Out. The setups are conflicting (Trend vs. Momentum disagreement).
Configuration You can toggle each strategy on/off in the settings menu. You can also choose to display the Overbought/Oversold background zones to visualize where the Stoch Pullback is "arming".
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.