OPEN-SOURCE SCRIPT
TradeShaper Supply & Demand

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.
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.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
TradeShaper — your private trading mentor. A decision-grading journal for options swing traders. tradeshaper.co/tour?utm_source=tradingview&utm_campaign=pine_signature
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
TradeShaper — your private trading mentor. A decision-grading journal for options swing traders. tradeshaper.co/tour?utm_source=tradingview&utm_campaign=pine_signature
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.