比爾·威廉斯 VolumeBill WilliamsBar Colour 在 Builder 中可用

BW Market Facilitation Index

Market Facilitation Index

Bill Williams' Market Facilitation Index divides a bar's range by its volume: how much price movement each unit of participation bought. The number alone says little — what the indicator is read for is its colour, and the colour encodes two changes at once, the index against the previous bar and the volume against the previous bar, which is four states rather than two.

Parameters
None
Colour states
4
Volume used
Tick
Zero — the floor, not a crossingBW MFI — (high − low) / volume; colour = index change × volume change

示意性 — 合成資料,非即時報價。

What the Market Facilitation Index tells you

Divide how far a bar travelled by how much trading it took, and you get a measure of how efficiently the market moved. A wide bar on light volume scores high — price went a long way for very little participation. A narrow bar on heavy volume scores low — a lot of trading produced almost no movement. Bill Williams' point was that neither reading means anything on its own: what matters is whether the index and the volume rose or fell together, and it is the combination that MT5 turns into a bar colour. Four combinations, four colours, and the two that share a colour on most other indicators are exactly the two Bill Williams wanted separated.

  • Index up, volume up — the move is going somewhere and people are in it
  • Index up, volume down — price is moving on nobody's participation
  • Index down, volume up — a lot of trading and no progress
  • Index down, volume down — the market has stopped caring
  1. 1 Take the bar's high minus its low
  2. 2 Divide it by the bar's volume
  3. 3 Colour the bar by whether that number and the volume each rose
顯示公式與計算詳情

The Market Facilitation Index is one division:

  1. BW MFI = (high − low) / volume

That is the whole calculation. There is no averaging window, no applied price and no method — each bar’s value comes from that bar and nothing else. In MQL5 the call is iBWMFI(symbol, period, applied_volume): three arguments, the fewest of any indicator the Builder exposes, and the second one is the timeframe rather than a length.

The number answers a narrow question: how much price movement did each unit of trading buy? But Bill Williams did not intend it to be read as a number. What he defined was a pair of readings — the index and the volume — and four cases depending on whether each rose or fell against the previous bar. MT5 renders those four as bar colours, and the four have names: green (both up), fade (both down), fake (index up, volume down) and squat (index down, volume up). MetaQuotes’ own demo for iBWMFI declares the plot as DRAW_COLOR_HISTOGRAM with clrLime, clrSaddleBrown, clrBlue, clrPink, in that order.

Two things about this are worth stating plainly.

Colour is not direction. All four states occur on rising bars and on falling bars alike. Green says the market moved efficiently and more people traded; it does not say which way. Any rule built on colour alone needs a direction from somewhere else, and the Builder’s template takes the cheapest honest one — the same bar’s close against its open.

The four states are reachable, unlike most colours on this site. The Awesome and Accelerator oscillators colour their bars by one comparison that MT5 performs at draw time, which an EA cannot read and must recreate. Here the colour is also outside what the Builder’s node returns — it reads buffer index 0 — but the rule behind it is two comparisons of published values, so recreating it is exact rather than approximate. Whether MQL5 additionally exposes the colour as a second buffer is something MetaQuotes’ reference and its own example disagree about; the template does not need the answer.

One implementation detail follows from the formula rather than from the platform. Both halves of the colour are per-bar quantities that are only complete when the bar is. The template therefore compares shift 1 against shift 2 — the bar that just closed against the one before it — where the AC template compares shift 0 against shift 1. Read the forming bar instead and the volume condition is almost never true, because on the first tick of a new bar the tick count is one.

訊號

BW MFI 提供的可回測訊號 — 及每個訊號適合的市場狀態。

Green — Index Up, Volume Up

Builder 可實現
條件
Both the index and the volume are higher than on the previous bar
最佳市場狀態
Trend continuation
典型用法
The template's condition — take the move only when participation came with it

Fake — Index Up, Volume Down

Builder 可實現
條件
The index rose while the volume fell
最佳市場狀態
Trend exhaustion
典型用法
Decline a breakout that nobody joined

Squat — Index Down, Volume Up

Builder 可實現
條件
The index fell while the volume rose
最佳市場狀態
Either regime
典型用法
The bar Bill Williams watched most: heavy trading with no progress often precedes the turn

Fade — Index Down, Volume Down

Builder 可實現
條件
Both fell
最佳市場狀態
Range
典型用法
Stand aside; there is neither movement nor interest

MT5 實作

MetaTrader 5 實際計算與繪製的內容——本頁每條規則的依據。

緩衝區

索引 緩衝區 MT5 中的繪製方式 存放內容
0 MAIN_LINE Histogram The index value — (high − low) / volume for the bar. Always positive, drawn as a histogram standing on zero. This is the buffer the Builder's node reads.
1 COLOR_INDEX Colour index Which of the four colours MT5 paints the bar. The reference text says iBWMFI has one buffer, but MetaQuotes' own demo for this function copies index 1 from the iBWMFI handle and calls it the histogram's colours. The Builder's node does not read it — see the caveat.

平台說明

最佳適用場景 / 謹慎使用

沒有任何指標具有普適優勢。以下是 BW MFI 發揮作用的場景 — 以及可能誤導的場景。

最佳適用場景

  • Confirming that a breakout bar had participation rather than drifting through a thin session
  • Timeframes where a bar is long enough for its volume to mean something — M30 and above
  • Alongside a direction source, since the index says nothing about which way price went
  • Instruments and sessions where the tick count actually reflects activity

謹慎使用

  • The forming bar — its range and its volume are both incomplete, so comparing it with a finished bar is comparing two different things
  • Any fixed threshold on the value; it carries the instrument's price units divided by a broker-specific tick count
  • Reading a colour as a direction — all four states occur on up bars and on down bars alike
  • Bars that gap, where the range understates how far the market actually moved

構建 BW MFI 策略

將訊號接入進場和出場規則,然後匯出可編譯的 MT5 EA — 無需撰寫程式碼。

  1. BW MFI at the bar that just closed (shift 1) and the one before it (shift 2)
  2. Volumes at the same two bars
  3. Both higher than the bar before → the state MT5 paints green
  4. The same bar's Close against its Open supplies the direction
  5. Green AND a bullish bar → Open Buy · SL 50 / TP 150; the mirrored pair → Open Sell

將 BW MFI 與其他指標組合

單一指標很少獨立有效。這些組合彌補了 BW MFI 的盲點。

BW MFI + Alligator

  1. Alligator lines fanned out
  2. Index and volume both rising
  3. Buy
原因
The rest of Bill Williams' own system. The Market Facilitation Index says whether a bar was worth anything; the Alligator says whether the market is trending or asleep. A green bar inside a sleeping Alligator is efficiency without a direction to spend it on, which is the case the index cannot rule out by itself
最佳市場狀態
Trending

No single-flow template combines them. Start from BW MFI Green Bar and add Alligator nodes for Jaw and Lips with a Compare between them, joined into the existing AND tree.

開啟 Builder →

BW MFI + Awesome Oscillator

  1. AO above zero
  2. Index and volume both rising
  3. Buy
原因
AO supplies the direction the index refuses to give. The template takes direction from the bar's own close against its open, which is the cheapest possible answer; an AO reading above zero replaces one bar's opinion with a 34-bar one
最佳市場狀態
Trending

No single-flow template pairs them. Start from BW MFI Green Bar, add an AO node with a Compare against a Constant of 0, and feed it into the AND tree in place of the Close-versus-Open pair.

開啟 Builder →

BW MFI + OBV

  1. OBV above its value 20 bars ago
  2. Index and volume both rising
  3. Buy
原因
Both read the same tick volume and disagree about what to do with it. OBV accumulates it into a running total and asks where the flow has been going; the index divides a single bar's range by it and asks what that one bar's trading achieved. Requiring the long accumulation to agree with a green bar separates an efficient bar inside the flow from one running against it
最佳市場狀態
Trending

No single-flow template pairs the two. Start from BW MFI Green Bar and add an OBV node plus a second OBV node at a shift, compared against each other — OBV has no zero to cross, so it is always read against its own past.

開啟 Builder →

參數

在您自己的貨幣對和時間框架上驗證的起始值 — 非保證設置。

參數 預設值 建議測試範圍 功能說明
Shift 0 0–30 Which bar back the node reads the buffer from. It is the only setting that changes what the node returns, and the template depends on it: two BW MFI nodes at shift 1 and shift 2 are how 'higher than the bar before' — half of what MT5 shows as a colour — becomes a condition an EA can test.
Timeframe Current M1–MN1 Which chart the reading comes from. Because the index has no period, the timeframe is the only thing that changes how much market each reading covers.
Applied volume Tick volume Tick or Real Which volume series divides the range. The Builder fixes this to tick volume, because real volume is unavailable on most retail forex feeds. It is the third and last argument iBWMFI takes.
Period Not applicable There is none. iBWMFI has no averaging window at all — each bar's value is computed from that bar alone, which is why two consecutive readings can differ by a large factor with nothing wrong.

初始預設

There are none iBWMFI takes a symbol, a timeframe and a volume type. Nothing else exists to preset.

市場示例

BW MFI 有效的場景、失效的場景,以及篩選器如何改變結果。

有效

A green bar that carried on

A breakout bar prints a wider range than the one before it on a higher tick count, and it closes above its open. The entry fires on the next bar's first tick and the fixed target is reached before the stop.

失效

Green in a thin session

A quiet stretch where a slightly wider bar arrives on a slightly higher tick count. Both conditions are technically true and the whole move is a few pips wide.

已篩選

The Fake bar the rule declines

Price breaks out on a wide bar, but the tick count fell against the previous bar — MT5 paints this blue, not green. The index rose, so half the condition is met; the volume condition is not, and the template declines the entry.

FAQ

What do the four colours mean?
They are two independent yes/no questions asked at once: did the index rise against the previous bar, and did the volume rise against the previous bar. Both up is the state usually called green — the move went somewhere and people were in it. Index up with volume down is the 'fake' bar: movement without participation. Index down with volume up is the 'squat' bar, the one Bill Williams watched most closely, where heavy trading produced no progress. Both down is the fade: nothing happening and nobody interested. MetaQuotes' own demo for iBWMFI declares them in that order as Lime, SaddleBrown, Blue and Pink.
What settings should I use?
There are none. iBWMFI takes a symbol, a timeframe and a volume type — three arguments, the fewest of any indicator node in the Builder. Each bar's value is computed from that bar alone, with no averaging window at all. The only choices you actually make are which timeframe to read it on and what to pair it with.
Can an EA read the bar colour?
The Builder's node cannot — it reads buffer index 0, which is the value. Whether the colour is reachable at all in MQL5 is genuinely ambiguous in MetaQuotes' documentation: the reference says iBWMFI has one buffer, while the example on the same page copies index 1 from the iBWMFI handle as the colours. Either way, the colour is two comparisons and both are expressible as nodes, so the template rebuilds it rather than depending on the answer.
Why does the template use shift 1 and shift 2 instead of shift 0 and shift 1?
Because the forming bar is not comparable with a finished one. Its range has not finished widening and its volume has barely started counting — on the first tick of a new bar the tick count is about one. A rule that asked 'is this bar's volume higher than the last bar's' about the forming bar would be false almost always, and true only by accident. Reading the bar that just closed against the one before it compares two completed bars, which is what MT5's colour does.
Can I build a BW MFI EA without coding?
Yes. The BW MFI Green Bar template reads the index at shift 1 and shift 2, reads Volumes at the same two bars, and requires both to have risen — the condition MT5 paints green. Direction comes from that bar's own close against its open, so a green bullish bar buys and a green bearish bar sells. Since the indicator has no parameters, the EA inputs are the stop distances and the spread and position limits.
How should I validate settings before going live?
Backtest on quality tick data, then run on a demo account before risking money. Half of every colour depends on the tick count, which is broker-specific, so results carried over from someone else's data deserve more scepticism than usual — re-run them on the feed you will actually trade. Check the trade count as well as the profit: requiring two rises and a candle direction at once is a narrow filter, and a flattering curve built on a handful of entries is not evidence.

Glossary

關鍵術語