Three Wise Man
- Indicatori
- Versione: 2.40
- Attivazioni: 10
Three Wisemen v2.40 is a MetaTrader 5 indicator that reproduces Bill Williams' classic sequence as described in the book — not as a simplified "arrows-on-a-chart" interpretation. Each of the three wisemen is a separately verified stage, and the whole sequence is a finite state machine that cannot be short-circuited.
What the three wisemen are
In Williams' framework a reversal is confirmed by three consecutive events, and only their combination justifies an entry:
- Wiseman 1 — the reversal bar. Its extreme exceeds the extremes of preceding bars while the close stays in the far half of the bar's range. Additionally, Alligator angulation is verified: price must separate from the jaw lines by a distance measured in ATR and at an angle measured in degrees. This is what distinguishes a genuine reversal from sideways noise inside the mouth.
- Wiseman 2 — a run of N consecutive Awesome Oscillator bars of the same colour. Colour is defined by slope, not by sign: green when AO rises, red when AO falls. This matches Williams' definition and works correctly both above and below the zero line.
- Wiseman 3 — a confirmed Bill Williams fractal. The fractal's price becomes the pending order level: a horizontal ray is drawn from it, and the entry signal appears only when price leaves that level.
The key architectural decision: two independent chains
Most implementations track one sequence at a time. While a bearish chain is alive, a bullish signal is discarded or queued — and effectively lost, because the AO bars are already in the past by the time the queue activates.
v2.40 has no such limitation. Each direction runs its own state machine W1 → W2 → Level → Breakout . A bullish Wiseman 1 owns only the bullish chain, a bearish one owns only the bearish chain. Neither can block, restart, or corrupt the other. At a reversal you see both pictures simultaneously — which is exactly what an undecided market looks like.
Non-repainting by construction
- The entire calculation window is replayed from scratch on every call; state is reconstructed deterministically.
- Signals fire only on a closed bar.
- The Wiseman 3 level is fixed at the confirmed fractal bar and never shifts.
- Arrows are placed on the event bar and are never moved retroactively.
Features
- Classic Alligator (13/8, 8/5, 5/3) with configurable periods and shifts, computed internally.
- Wilder ATR normalisation for every threshold — parameters are instrument- and timeframe-independent.
- Three angulation modes: distance only (ATR units), angle only (degrees), or both.
- Three bar-vs-mouth modes: extreme piercing, whole bar outside, close outside.
- Context filters: Alligator fan in the trade direction, price arriving from inside the mouth.
- Three policies for an opposite Wiseman 1: independent chains (default), ignore, immediate reversal.
- Switchable invalidation logic: by bar close or by full extreme.
- The protective extreme is widened automatically on repeat same-direction signals — without discarding the AO count already accumulated.
- Alerts at every stage: W1, W2, W3 level appearance, and level breakout — popup, push, sound.
- Per-bar debug report: a component-by-component breakdown of every condition with a PASS/FAIL verdict.
Parameters
| Parameter | Purpose | Default |
|---|---|---|
| InpBarsToCalculate | Calculation depth in bars (0 = full history) | 3000 |
| InpClosedBarsOnly | Closed bars only | true |
| InpAtrPeriod | ATR period for normalisation | 14 |
| InpJawPeriod / InpJawShift | Alligator jaw | 13 / 8 |
| InpTeethPeriod / InpTeethShift | Alligator teeth | 8 / 5 |
| InpLipsPeriod / InpLipsShift | Alligator lips | 5 / 3 |
| InpPrevBars | Prior extremes W1 must exceed | 2 |
| InpCloseHalf | Required close position within the bar | 0.50 |
| InpMinRangeATR | Minimum bar range, ATR | 0.50 |
| InpAngulationMode | Angulation check mode | Distance + angle |
| InpSepMinATR / InpDeltaSepATR | Minimum separation and its growth, ATR | 0.30 / 0.05 |
| InpAngleMinDeg | Minimum divergence angle, degrees | 15.0 |
| InpMouthMode | Bar position vs the mouth | Extreme piercing |
| InpAO_Fast / InpAO_Slow | Awesome Oscillator periods | 5 / 34 |
| InpW2Bars | AO bars required for W2 | 3 |
| InpW1TimeoutBars | Wiseman 2 waiting timeout, bars | 12 |
| InpFractalHalf | Fractal half-width (2 = classic 5-bar) | 2 |
| InpW3OutsideTeeth | Fractal must be beyond the Teeth | true |
| InpW3UseClose | Breakout by close (false = by High/Low) | true |
| InpW3TimeoutBars | W3 level lifetime, bars | 20 |
| InpOppW1Policy | Opposite Wiseman 1 policy | Independent chains |
| InpInvalidateUseClose | Invalidate by close (false = by extreme) | true |
How to use
- Attach to any chart. The indicator works on all timeframes.
- Wait for Wiseman 1 — arrows mark the bar.
- When Wiseman 2 appears, watch the horizontal line: it is the fractal price, i.e. the pending order level.
- Enter on the breakout of that line in the direction of the chain. The Wiseman 3 arrow marks the breakout.
- Protective stop goes beyond the Wiseman 1 bar's extreme; when a chain dies, its level is greyed out.
Recommended settings by timeframe
| Timeframe | InpW2Bars | InpAngleMinDeg | InpW1TimeoutBars |
|---|---|---|---|
| M5–M15 | 3–4 | 12–15 | 10–15 |
| M30–H1 | 4–5 | 15–20 | 12–20 |
| H4–D1 | 5 (classic) | 15–25 | 20–30 |
On lower timeframes the classic run of five AO bars produces very few signals; reducing it to 3–4 is reasonable but demands strict risk discipline.
Important
This indicator is a tool for analysis and study. It does not place trades and is not trading advice. Williams' system assumes disciplined money management and trading in the direction of the higher-timeframe trend; counter-trend signals require confirmation. Test on a demo account first.
