PROTECTED SOURCE SCRIPT
更新済 Swing Pivots - Market Structure High Low [zazenio]

What is Market Structure?
Market structure is simply the pattern of highs and lows that price creates as it moves. When you look at any chart, you'll notice price doesn't move in a straight line — it swings up, pulls back, swings up again (in an uptrend), or the opposite in a downtrend.
These swing points — the peaks and valleys — are what traders call pivots. Identifying them correctly is the foundation of understanding where a market has been and where it might go next.
What This Indicator Does
Swing Pivots automatically marks these peaks and valleys on your chart so you don't have to draw them manually. It works on any market — stocks, crypto, forex, futures, indices — and on any timeframe.
How Pivots Are Detected
This indicator confirms pivots based on price structure, not a fixed bar count.
Here's how it works:
A swing high is confirmed when price breaks below the previous swing low. At that moment, we know the high was real — price tried to go higher, failed, and reversed. The market "proved" that level was a genuine turning point.
A swing low is confirmed when price breaks above the previous swing high. The same logic applies — price tried to go lower, failed, and reversed direction.
This creates a natural alternation: high, low, high, low. Each pivot is validated by the market's actual behavior, not by waiting for an arbitrary number of bars to pass.
Why This Matters
Most pivot indicators use a "lookback" method — they wait for a certain number of bars (say, 5 or 10) on each side of a candle before confirming it as a pivot. This creates a fixed delay. By the time the pivot appears on your chart, price has already moved on.
This indicator doesn't wait. It confirms pivots the moment price structure proves them. The result is pivots that align with how traders actually read charts — based on breaks of structure, not arbitrary countdowns.
Settings
Use Cases
⸻
Disclaimer:
This script is provided for educational and informational purposes only. It is not financial advice and does not constitute a recommendation to buy or sell any financial instrument. Always do your own research and trade at your own risk.
Market structure is simply the pattern of highs and lows that price creates as it moves. When you look at any chart, you'll notice price doesn't move in a straight line — it swings up, pulls back, swings up again (in an uptrend), or the opposite in a downtrend.
These swing points — the peaks and valleys — are what traders call pivots. Identifying them correctly is the foundation of understanding where a market has been and where it might go next.
What This Indicator Does
Swing Pivots automatically marks these peaks and valleys on your chart so you don't have to draw them manually. It works on any market — stocks, crypto, forex, futures, indices — and on any timeframe.
How Pivots Are Detected
This indicator confirms pivots based on price structure, not a fixed bar count.
Here's how it works:
A swing high is confirmed when price breaks below the previous swing low. At that moment, we know the high was real — price tried to go higher, failed, and reversed. The market "proved" that level was a genuine turning point.
A swing low is confirmed when price breaks above the previous swing high. The same logic applies — price tried to go lower, failed, and reversed direction.
This creates a natural alternation: high, low, high, low. Each pivot is validated by the market's actual behavior, not by waiting for an arbitrary number of bars to pass.
Why This Matters
Most pivot indicators use a "lookback" method — they wait for a certain number of bars (say, 5 or 10) on each side of a candle before confirming it as a pivot. This creates a fixed delay. By the time the pivot appears on your chart, price has already moved on.
This indicator doesn't wait. It confirms pivots the moment price structure proves them. The result is pivots that align with how traders actually read charts — based on breaks of structure, not arbitrary countdowns.
Settings
- Swing Width: Controls how sensitive the detection is. Higher numbers show only major swings; lower numbers capture smaller moves within the structure.
- Style/Size/Colors: Customize how the pivot markers look on your chart.
Use Cases
- See the "skeleton" of price action at a glance
- Identify potential support and resistance levels
- Understand if the market is trending or ranging
- Build a foundation for more advanced concepts like Break of Structure (BOS) and Change of Character (CHoCH)
⸻
Disclaimer:
This script is provided for educational and informational purposes only. It is not financial advice and does not constitute a recommendation to buy or sell any financial instrument. Always do your own research and trade at your own risk.
リリースノート
What is Market Structure?Market structure is simply the pattern of highs and lows that price creates as it moves. When you look at any chart, you'll notice price doesn't move in a straight line — it swings up, pulls back, swings up again (in an uptrend), or the opposite in a downtrend.
These swing points — the peaks and valleys — are what traders call pivots. Identifying them correctly is the foundation of understanding where a market has been and where it might go next.
What This Indicator Does
Swing Pivots automatically marks these peaks and valleys on your chart so you don't have to draw them manually. It works on any market — stocks, crypto, forex, futures, indices — and on any timeframe.
Beyond just marking pivots, this indicator also draws BOS (Break of Structure) and CHoCH (Change of Character) lines — two essential concepts that help you understand when a trend is continuing or potentially reversing.
How Pivots Are Detected
This indicator confirms pivots based on price structure, not a fixed bar count.
Here's how it works:
A swing high is confirmed when price breaks below the previous swing low. At that moment, we know the high was real — price tried to go higher, failed, and reversed. The market "proved" that level was a genuine turning point.
A swing low is confirmed when price breaks above the previous swing high. The same logic applies — price tried to go lower, failed, and reversed direction.
This creates a natural alternation: high, low, high, low. Each pivot is validated by the market's actual behavior, not by waiting for an arbitrary number of bars to pass.
Understanding BOS and CHoCH
Once you can identify pivots, the next step is understanding what happens when price breaks through them. This is where BOS and CHoCH come in.
BOS (Break of Structure)
A Break of Structure occurs when price continues in the direction of the current trend by breaking a previous pivot level.
- In an uptrend: Price breaks above a previous swing high → This signals strength. Buyers are pushing price to new highs, and the trend is likely to continue.
- In a downtrend: Price breaks below a previous swing low → This signals weakness. Sellers are pushing price to new lows, and the trend is likely to continue.
Think of BOS as the market saying "the trend is still intact." Each BOS confirms that the dominant side (buyers or sellers) remains in control.
CHoCH (Change of Character)
A Change of Character occurs when price breaks a pivot level in the opposite direction of the current trend. This is an early warning signal that the trend may be reversing.
- In an uptrend: Price breaks below a previous swing low → This is unexpected. In a healthy uptrend, lows should hold. When they don't, it suggests buyers are losing control and sellers may be taking over.
- In a downtrend: Price breaks above a previous swing high → This is unexpected. In a healthy downtrend, highs should hold. When they don't, it suggests sellers are losing control and buyers may be stepping in.
Think of CHoCH as the market's behavior "changing character" — it's no longer acting the way it should if the trend were healthy.
Why BOS and CHoCH Matter
These concepts give you a framework for reading what the market is actually doing:
- BOS tells you the trend is continuing — stay with it or look for entries in that direction
- CHoCH warns you the trend may be ending — time to be cautious, take profits, or look for trades in the new direction
By visualizing these breaks directly on your chart, you don't have to guess. You can see at a glance whether the market is trending smoothly (consecutive BOS) or showing signs of reversal (CHoCH).
Why This Approach Works
Most pivot indicators use a "lookback" method — they wait for a certain number of bars (say, 5 or 10) on each side of a candle before confirming it as a pivot. This creates a fixed delay. By the time the pivot appears on your chart, price has already moved on.
This indicator doesn't wait. It confirms pivots the moment price structure proves them. The result is pivots that align with how traders actually read charts — based on breaks of structure, not arbitrary countdowns.
Settings
Configuration
- Swing Width: Controls how sensitive the detection is. Higher numbers show only major swings; lower numbers capture smaller moves within the structure.
Pivot Settings
- High/Low Color: Customize the colors of swing high and swing low markers
- Style: Choose between Triangle or Circle markers
- Size: Adjust the size of pivot markers (Auto, Tiny, Small, Normal)
Structure Lines
- Show CHoCH: Toggle Change of Character lines on/off
- CHoCH Color: Customize the color of CHoCH lines
- CHoCH Label: Show/hide the "CHoCH" text label
- Show BOS: Toggle Break of Structure lines on/off
- BOS Color: Customize the color of BOS lines
- BOS Label: Show/hide the "BOS" text label
Use Cases
- See the "skeleton" of price action at a glance
- Identify potential support and resistance levels
- Understand if the market is trending or ranging
- Spot trend continuations with BOS lines
- Catch early reversal signals with CHoCH lines
- Build a foundation for more advanced trading strategies
━━━━━━━━━━━━━━━━━━━━━━
Version History
v1.1
- Added BOS (Break of Structure) lines to visualize trend continuation
- Added CHoCH (Change of Character) lines to identify potential trend reversals
- Added toggle options for BOS and CHoCH visibility
- Added customizable colors for structure lines
- Added optional labels for BOS and CHoCH
v1.0
- Initial release
- Automatic swing high and swing low detection
- Structure-based pivot confirmation (not fixed lookback)
- Customizable pivot markers (style, size, colors)
- Adjustable swing width sensitivity
━━━━━━━━━━━━━━━━━━━━━━
Disclaimer:
This script is provided for educational and informational purposes only. It is not financial advice and does not constitute a recommendation to buy or sell any financial instrument. Always do your own research and trade at your own risk.
保護スクリプト
このスクリプトのソースコードは非公開で投稿されています。 ただし、制限なく自由に使用できます – 詳細はこちらでご確認ください。
免責事項
この情報および投稿は、TradingViewが提供または推奨する金融、投資、トレード、その他のアドバイスや推奨を意図するものではなく、それらを構成するものでもありません。詳細は利用規約をご覧ください。
保護スクリプト
このスクリプトのソースコードは非公開で投稿されています。 ただし、制限なく自由に使用できます – 詳細はこちらでご確認ください。
免責事項
この情報および投稿は、TradingViewが提供または推奨する金融、投資、トレード、その他のアドバイスや推奨を意図するものではなく、それらを構成するものでもありません。詳細は利用規約をご覧ください。