OPEN-SOURCE SCRIPT

TradeShaper Supply & Demand

831
TradeShaper Supply & Demand

An inside-bar zone indicator that marks the supply and demand areas created when
price coils and then breaks — the inside candle's range becomes the zone, and the
zone stays live only until price returns to touch it.

The inside-candle formation this script keys off of is based on the supply and
demand methodology taught by Tr3ndy Jon (Jonathan McKeever). This is an
independent implementation of the concept, not affiliated with or endorsed by him.

HOW A ZONE IS BUILT

Three candles define the setup:

1. INITIAL — the candle that establishes the range.
2. INSIDE — the first candle whose close lands inside the initial candle's body.
Price may keep coiling for several bars, but the zone always anchors to this
first inside candle.
3. CONFIRMATION — a candle that closes beyond the initial candle. Close above the
initial high creates a DEMAND zone; close below the initial low creates a
SUPPLY zone. The confirming candle does not have to be the very next one; the
setup stays armed for a configurable number of bars.

The zone itself is the inside candle's full high-to-low range, wicks included.

READING THE ZONE

The EDGE is the side price approaches from — the low of a supply zone, the high of
a demand zone. Internal levels are drawn as a percentage of zone depth measured
inward from that edge, so 25% is always a shallow tag and 75% always deep,
regardless of which side you're on.

A zone is consumed the moment any later candle's wick enters it. Only untouched
zones stay on the chart. Zones project forward a fixed number of bars and stop
extending once a newer zone forms.

SETTINGS

Formation — inside-candle definition (close-inside-body or full inside bar), what
the confirming candle must close beyond, and how long a coiling setup stays armed.

Zone — forward projection, what happens when a wick enters a zone (delete or gray
out), and how many zones to keep per side.

Internal levels — any percentages you want (25/50/75 by default, or 38.2/50/61.8
for Fibonacci ratios), each with its own color.

Debug — marks the initial and inside candles and draws the exact levels a candle
must close beyond to confirm. Useful for verifying the logic against your own
reading of the chart.

Alerts fire when price tags a virgin supply or demand edge.

إخلاء المسؤولية

لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.