PROTECTED SOURCE SCRIPT

Velez Master Narrow Scanner

26
The Velez Master Narrow Scanner is a specialized technical analysis tool designed for the TradingView platform. Its primary purpose is to automate the discovery of the "Narrow State"—a core concept in Oliver Velez’s professional trading methodology.

🧩 Core Functionality

The scanner monitors the relationship between two specific moving averages:

20-period Simple Moving Average (20 SMA): Represents short-term market momentum and the "trader's trend."

200-period Simple Moving Average (200 SMA): Represents the long-term "institutional anchor" or fair value.

A "Narrow State" occurs when these two lines converge significantly (typically within a 1.2% to 1.5% range). This indicates a period of price compression and low volatility, where short-term traders and long-term institutions are in rare agreement. In the Velez philosophy, this state acts like a "coiled spring," usually preceding an explosive breakout.
+2

⚡ Key Features of the Scanner

Distance Measurement: Calculates the precise percentage gap between the 20 and 200 SMAs to ensure the "coil" is tight enough to meet professional criteria.

Stability Logic (Duration): Unlike standard filters, this master version tracks how long the stock has remained in the narrow state. It only triggers a signal if the convergence has been stable for a user-defined number of bars (e.g., 30 minutes of consolidation).

Previous Day Closing Scan: Specifically designed for pre-market preparation, the scanner evaluates the state of the averages at the end of the previous trading day, allowing you to build a "Battle Plan" before the market opens.

Pine Screener Integration: The script outputs a discrete binary signal (1 for a match, 0 for no match), allowing you to filter entire watchlists or the entire US stock market in seconds.

🚀 Strategic Application

Traders use this scanner to move away from "chasing" momentum and instead focus on anticipating it. When the scanner identifies a stock in a stable Narrow State, the trader waits for an "Elephant Bar" (a large, solid-bodied institutional candle) to break out from the averages.

By identifying these setups, you are positioning yourself at the very origin of a new trend, typically resulting in a higher reward-to-risk ratio.

2. How to Scan Your Selection (Step-by-Step)
Step A: Set the Timeframe

If you want to scan for a state that lasted 30 minutes:
Set your main TradingView chart to the 5-minute timeframe.

Set the Min. Consecutive Bars in the script settings to 6 (5×6=30).

If you want to scan for a state that lasted 2 hours:
Set your chart to the 15-minute timeframe.
Set the Min. Consecutive Bars to 8 (15×8=120 mins).

Step B: Set up the Pine Screener
Open the Pine Screener at the bottom of your screen.
Click the "Scope" or "Watchlist" button (top left of the screener) and select your Favourites/Selection list.

Click "Add Filter".
Search for your script: "Velez Master Narrow Scanner".
Select the "Scan Signal" column.
Set the condition to "Equals" and type 1.

3. Summary of Settings for 30 Minutes

Chart Timeframe Bars in Script Total Time Measured
1 Minute 30 30 Minutes
5 Minutes 6 30 Minutes
15 Minutes 2 30 Minutes

Haftungsausschluss

Die Informationen und Veröffentlichungen sind nicht als Finanz-, Anlage-, Handels- oder andere Arten von Ratschlägen oder Empfehlungen gedacht, die von TradingView bereitgestellt oder gebilligt werden, und stellen diese nicht dar. Lesen Sie mehr in den Nutzungsbedingungen.