How it works
The Ultimate Oscillator exists to solve a specific, well-identified problem with single-period oscillators: their signals depend heavily on the lookback you happened to choose, and a divergence that looks compelling on a 7-period setting can be absent on a 21-period one. Its answer is to compute the same momentum measure over three windows — short, medium and long — and combine them with fixed weights so that no single horizon dominates.
The underlying quantity is more thoughtful than a simple price change. For each bar it computes 'buying pressure': the close minus the lower of the current low and the previous close. That lower bound accounts for gaps, so a market that gapped down and then rallied to close near the top of the day is correctly credited with strong buying, which a plain close-to-close measure would miss. Buying pressure is then divided by the true range over the same window, giving the fraction of the ground covered that buyers were responsible for.
The weights, four to two to one favouring the shortest window, mean the oscillator is responsive but never at the mercy of a single fast reading. Because both numerator and denominator are sums over the same bars, the result is naturally bounded between 0 and 100 without any clamping, and 50 is a genuine neutral point where buyers and sellers accounted for equal shares of the range.
Its author specified an unusually precise signal rather than leaving interpretation open. The bullish case requires three things together: a bullish divergence where price makes a lower low but the oscillator does not, a reading below 30 at the oscillator's low point during that divergence, and then a break above the divergence's high on the oscillator. Requiring all three makes signals rare, which is the point — this is a tool designed for a handful of high-quality setups per year on a daily chart, not a continuous stream.
Compared with RSI, the Ultimate Oscillator is less prone to divergences that appear and vanish with a parameter change, and its use of true range makes it better behaved around gaps. The price is complexity: three windows and a weighting scheme mean it is harder to reason about when it misbehaves, and its readings are less intuitive than a single-horizon oscillator's.
Calculation
The arithmetic in words, in the order it happens.
For each bar, buying pressure BP = close - the lower of (current low, previous close). True range TR = the higher of (current high, previous close) minus the lower of (current low, previous close). Then form three averages by summing over three windows: Avg7 = sum of BP over 7 bars / sum of TR over 7 bars, and likewise Avg14 over 14 bars and Avg28 over 28 bars. The oscillator is the weighted blend UO = 100 x (4 x Avg7 + 2 x Avg14 + 1 x Avg28) / 7. Because each average is a ratio of sums of non-negative quantities where BP never exceeds TR, the result is naturally bounded between 0 and 100 with 50 as neutral.
Source
An AlgoBeamScript implementation of the formula above, written by us from the arithmetic so the code and the calculation agree line for line.
Runs unchanged on the platform and in the AlgoBeamTS runtime. The language reference is in the documentation.
Inputs
Defaults are the values most charting packages ship with. They are conventions, not optimal settings — the right length depends on your instrument and your holding period.
| Input | Default | What it changes |
|---|---|---|
| Fast Length | 7 | Shortest of the three windows and the one carrying the heaviest weight. Shortening it makes the oscillator considerably more reactive and undoes much of the multi-timeframe smoothing the design is built around. |
| Middle Length | 14 | The intermediate horizon, conventionally double the fast length. It is the stabilising term and is rarely changed independently of the other two. |
| Slow Length | 28 | Longest window, conventionally double the middle. Extending it anchors the oscillator to a slower regime and reduces how often it visits its extremes. |
| Overbought / oversold levels | 70 / 30 | Guide lines that match the author's own signal specification, where the 30 level is a required condition for the bullish setup rather than a trigger in itself. |
How to read it
What practitioners take from the plot. Read these as descriptions of market state, not as entry signals.
- Above 70
- Buyers have accounted for a large share of the range across all three horizons. Strong, but the tool was not designed to be sold at this level on its own.
- Below 30
- Sellers have dominated across all three windows. A precondition of the classic bullish setup rather than a buy signal by itself.
- Bullish divergence with the low below 30
- Price made a lower low while the oscillator did not, from a genuinely washed-out level. The first two of the three conditions in the author's specification.
- Break above the divergence high
- The confirming third condition. Requiring it filters out the many divergences that never resolve into anything.
- Sitting near 50 for an extended stretch
- Buyers and sellers are splitting the range evenly across every horizon — a balanced market where the oscillator has nothing to add.
Limitations
Where this indicator misleads. None of these are fixed by a better parameter.
- Blending three windows makes it slower to react than any single-period oscillator, so it will miss the first part of a fast move by design.
- The full three-condition signal is rare. Traders who relax it to a plain divergence lose most of the filtering that makes the tool worth using.
- With three lengths and a fixed weighting, it has more parameters than its neighbours and is correspondingly easier to overfit and harder to diagnose when it fails.
- It still saturates in sustained trends: readings can hold above 70 through an entire advance, and countertrend rules built on the threshold alone will fire repeatedly against the move.
Educational reference. This page explains how an indicator is built and how it is commonly read. It is not investment advice, not a recommendation and not a signal service. No indicator is profitable on its own — each is a way of describing a market, and any rule built on one has to be tested with realistic costs before it is traded.