.png)

๐ What the Indicator Does
MarketStructureOscSignals is a pure price-action signal tool.
It:
- Detects swing highs and swing lows using a left/right lookback.
- Tracks whether those swings are forming:
- Higher Highs + Higher Lows โ Bullish structure
- Lower Highs + Lower Lows โ Bearish structure
- When the structure switches:
- From bearish โ bullish โ it plots a BUY signal
- From bullish โ bearish โ it plots a SELL signal
So every signal represents a true change in market structure, not just a moving average crossover.
โ๏ธ Inputs & How to Set Them
1. Swing Left / Swing Right
These control how โstrictโ a swing high/low is.
- Swing Left (default 2)
Number of bars to the left of the swing that must have lower highs (for a swing high) or higher lows (for a swing low). - Swing Right (default 2)
Number of bars to the right that must also confirm the swing.
How to use:
- Small values (1โ2):
- More swings, more signals
- Works well on higher timeframes (H1, H4, D1)
- Larger values (3โ4+):
- Only major structural turns
- Fewer but stronger signals
- Good on lower timeframes to avoid noise
2. Min Bars Between Signals
Minimum number of bars that must pass between two signals.
- Avoids clustering of arrows on every tiny pullback.
- Example:
- Set to
3โ at least 3 bars between one signal and the next. - On very fast charts (M1โM5) you might want
5โ10. - On H1 or higher,
2โ3is usually enough.
- Set to
3. Arrow Offset (pips)
How far the arrow and label are placed from the candle (in pips).
- For Forex:
5โ10pips usually looks good.
- For indices (US500, US100, etc.):
- Use a larger offset (e.g. 20โ50 โpipsโ depending on broker pip size).
If the arrows overlap the candles, increase this value.
If they are too far away, decrease it.
4. Show BUY/SELL Text
trueโ shows both an arrow (โ/โ) and the text โBUYโ or โSELLโ.falseโ only arrows.
If the chart feels cluttered, you can hide the text and keep just the arrows.
๐ How Signals Are Generated (Logic)
Internally the indicator:
- Keeps track of the two most recent swing highs and two most recent swing lows:
_prevHigh,_lastHigh_prevLow,_lastLow
- From these it checks:
- Are highs and lows both rising?
- โ Bullish trend (
StructureTrendSignal.Bullish)
- โ Bullish trend (
- Are highs and lows both falling?
- โ Bearish trend (
StructureTrendSignal.Bearish)
- โ Bearish trend (
- If theyโre not aligned, the previous trend is kept.
- Every time the structural trend changes:
Bearish โ Bullishโ BUY signalBullish โ Bearishโ SELL signal
- It also ensures:
- Trend was not
Unknown(so not at the very beginning). - Enough bars have passed since the last signal (
MinBarsBetweenSignals).
- Trend was not
This means each arrow marks a true structural shift, not random noise.
๐ How to Read BUY/SELL Signals on the Chart
โ BUY Signal
What you see:
- An up arrow
โunder the candle - Optionally the text โBUYโ near the arrow
What it means:
- Structure changed from bearish โ bullish.
- Recent swing highs and lows are now both moving up.
- Market is likely transitioning into a new uptrend or resuming bullish structure.
How to use it:
- Look for long entries:
- On the signal candle or on the next few candles.
- Preferably after a small pullback to a support level (previous swing low, demand zone, VWAP, VA low, etc.).
- Use tools like Kalman Trend / EMA / Volume Profile to filter:
- Only take BUYs when higher timeframe or Kalman is also bullish.
โ SELL Signal
What you see:
- A down arrow
โabove the candle - Optionally the text โSELLโ
What it means:
- Structure changed from bullish โ bearish.
- Swing highs and lows are now both moving down.
- Market is likely entering a downtrend or resuming bearish structure.
How to use it:
- Look for short entries:
- On the signal candle or on following candles near resistance.
- Ideal after a retest of a broken support (now resistance), VAH, supply zone, etc.
๐ฏ Practical Trading Uses
1. As a Standalone Entry Tool
Simple rule-set:
- Buy Setup
- Wait for a BUY arrow.
- Place a long order at/near the signal candle.
- Stop loss below recent swing low.
- Target previous swing high or a key resistance.
- Sell Setup
- Wait for a SELL arrow.
- Place a short order at/near the signal candle.
- Stop loss above recent swing high.
- Target previous swing low or key support.
This is the most basic usage and works best on H1, H4, and D1, where structure is cleaner.
2. As a Confirmation Tool with Your Other Indicators
This is where it gets powerful.
๐น With Kalman Filter Trend
- Only take BUY signals when:
- Kalman Trend is sloping up and price is at or above the Kalman line.
- Only take SELL signals when:
- Kalman Trend is sloping down and price is at or below the Kalman line.
Effect:
Kalman gives you a smooth trend, MarketStructureOscSignals gives you precise structure shifts. Together they filter out a lot of bad trades.
๐น With Volume Profile / Support & Resistance
- Strong BUY:
- BUY arrow appears near VA Low, previous swing low, or liquidity sweep, with rejection.
- Strong SELL:
- SELL arrow appears near VA High, previous swing high, or liquidity sweep at the top.
Here the signal is not just a technical pattern but is also anchored in liquidity and order flow zones.
3. For Scaling In / Out
You can also use new signals as:
- Scale-In Points
Add to a position when a new signal appears in the same direction as your existing trade and the higher timeframe is aligned. - Early Exit / Partial Exit
If youโre long and a SELL signal appears against your position (especially near key structure), you can: - Close a part of the position
- Or tighten stops
๐งช Recommended Starting Settings
For Forex H1 / H4:
Swing Left = 2Swing Right = 2Min Bars Between Signals = 3Arrow Offset = 5โ10 pips
For Indices M15 / H1:
Swing Left = 2โ3Swing Right = 2โ3Min Bars Between Signals = 5Arrow Offsetadapted to symbol (e.g. 20โ50 โpipsโ depending on broker)
For Crypto H1 / H4:
- Slightly higher swings to filter noise:
Swing Left = 3Swing Right = 3Min Bars Between Signals = 4โ6
Always backtest with your preferred instrument and timeframe to fine-tune Swing and MinBarsBetweenSignals.
.jpg)
.jpg)
.png)
.jpg)
.png)
.jpg)
.jpg)
 (1).png)
.png)
.png)
.png)
.png)
.jpg)
.jpg)
.png)
.png)
.png)
.png)
















.jpeg)