Williams %R

Where the close sits in the recent range, from -100 (at the low) to 0 (at the high).

Williams %R = −100 × (highest high − close) ÷ (highest high − lowest low) over the last length candles (current included), −100 to 0. A flat window is not ready. Mirror: midpoint −50 (a mirrored price turns the close's place in the range around).

Settings

SettingDefaultRangeWhat it does
length141 to 500Candles of the high-low window.

What it gives

OutputWhat it is
willr%R, −100–0.

What it reads

It reads the whole candle (open, high, low, close and volume).

Warm-up

With its default settings, Williams %R needs 14 closed candles before its first value. A backtest loads them before its start date, so the first trade can already use it.

Test it

Copy this sentence into the Algonney chat to backtest it:

Backtest a strategy on BTC that uses Williams %R with its default settings