Ultimate Oscillator

Buying pressure averaged over three time windows, from 0 to 100.

Ultimate Oscillator: buying pressure BP = close − min(low, previous close), true range TR; average_n = sum(BP) ÷ sum(TR) over the last n candles; UO = 100 × (4 × avg_fast + 2 × avg_mid + avg_slow) ÷ 7. Needs fast < mid < slow. Ready at slow + 1 candles; not ready when a TR sum is 0. Mirror: midpoint 50 (a mirrored price turns BP into TR − BP).

Settings

SettingDefaultRangeWhat it does
fast71 to 500Candles of the fast average.
mid141 to 500Candles of the middle average.
slow281 to 500Candles of the slow average.

What it gives

OutputWhat it is
uoUO, 0–100.

What it reads

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

Warm-up

With its default settings, Ultimate Oscillator needs 29 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 Ultimate Oscillator with its default settings