Signal Pilot
🟡 Intermediate • Lesson 51 of 85

Oscillators Under Regime

Reading time ~17 min • Module 6: Indicators, Honestly
Signal Pilot
Professional Trading Education
0%
You’re making progress!
Keep reading to mark this lesson complete

Two implementations of the same fourteen-bar oscillator, run over this module’s sixty closes. One prints thirteen readings above 70. The other prints none at all and never leaves the band from 45.1 to 67.5. Both are standard, both ship on platforms people trade from, and the only difference between them is which average smooths the gains and the losses. Take the version that speaks. Not one of its forty-six readings falls below 30 either, on a series that rises 5.8 points and closes up on 32 of its 59 bars, because the oscillator is bounded and the drift is not. And what follows those thirteen is nothing: of the twelve with five bars behind them the price is higher five bars later on 7, which is 58 per cent against a base rate of 58. What a reading of 70 actually asks for is an average gain seven thirds of the average loss, and at equal move sizes that is seven up bars in ten — a description of an ordinary advance. The level was never the signal.

Prerequisites: Lesson 48, which put a filter’s delay at the first moment of its weight vector and is where the 6.50 and the 13.00 below come from, lesson 36, whose efficiency ratio runs from 0.012 to 0.587 across the thirteen readings in the worked table and turns out to be the column doing the work, and lesson 50, which established that a level is worth nothing until it is set against the base rate of the tape doing what it does anyway, and priced separating the two at 609 observations.

One name, two numbers

The oscillator is a ratio and nothing more. Take the last fourteen bar-to-bar changes, average the rises, average the falls, and report the rises as a share of the two added together, multiplied by a hundred. A stretch with no falls in it reads 100. A stretch with no rises reads 0. Everything else lands in between, and the only judgement anywhere in that sentence is the word average.

That word carries the whole lesson. There are two ordinary ways to take it. A simple average over a fourteen-bar window weights the last fourteen changes equally and forgets everything older, and by lesson 48’s first moment it describes the market as it stood 6.50 bars ago. Wilder’s own smoothing, published with the indicator in 1978, keeps a fourteenth of each new change and fourteen-fifteenths of what it already held, which never forgets anything at all and whose first moment is 13.00 bars. Both are called a fourteen-period reading. One is twice as late as the other, and it never fully lets go of a loss.

Run both, at three periods, on the same sixty closes.

SettingReadingsAbove 70Below 30Range
7-bar, simple5312124.1 to 100.0
7-bar, Wilder539037.3 to 82.6
14-bar, simple4613036.7 to 81.0
14-bar, Wilder460045.1 to 67.5
21-bar, simple3910039.6 to 77.4
21-bar, Wilder390047.2 to 60.7

Read the two fourteen-bar rows against each other, because they are the setting almost everybody uses. Thirteen overbought readings and zero, on the same bars, in the same window length, from two averages that both have a claim to the name. The Wilder version at fourteen and at twenty-one never crosses 70 in either direction on this series; its whole range is twenty-two points wide at fourteen and thirteen points wide at twenty-one, while the simple version at seven bars reaches 100 and gets down to 24.1. The oscillator has a dial nobody prints, and it is not the period.

The mechanism is the memory. A simple window drops the oldest change entirely, so a fourteen-bar run of rises can empty the denominator and send the reading to 100. Wilder’s average never drops anything; a loss from thirty bars ago is still in there at a fourteenth of a fourteenth, so the denominator never quite empties and the reading never quite extends. That is not a defect in either. It is the trade lesson 48 priced: the smoother filter is later and steadier, and steadier here means it does not reach the levels the strategy is written around.

What seventy actually asks for

Set the reading to 70 and solve. A hundred times the average gain over the sum of the two equals 70 exactly when the average gain is seven thirds of the average loss, which is 2.3333. At 80 it is four to one. At 30 the average gain must be no more than three sevenths of the average loss, which is 0.4286.

Now put a size on the moves. If every up bar and every down bar in the window moves the same distance, the averages reduce to counts, and the reading becomes a hundred times the share of bars that closed up. So a reading of exactly 70 is exactly seven up bars in ten. Not a spike, not an extreme, not a market that has run too far: seven bars up and three bars down, which is what an ordinary advance looks like from the inside.

That is the whole of the arithmetic behind the word overbought, and it is worth sitting with, because almost nobody who uses the level has ever solved for it. Seven in ten is a condition a trending market satisfies routinely and a ranging market almost never does. The reading is not telling you the move has gone too far. It is telling you the last fourteen bars leaned one way, which you could have seen without it.

Why nothing here reads below 30

Forty-six readings and not one under 30 is the kind of result that looks like a bug and is arithmetic. The lowest reading on the whole series is 36.7 at bar 28. Its window holds 6 up bars and 8 down, an average gain of 0.6429 and an average loss of 1.1071, so the ratio is 0.5806. To print 30 that ratio would have to fall to 0.4286, which on a window of this width means a run of falls the series never produces.

And it never produces one because it drifts. The sixty closes rise 5.8 points end to end and close up on 32 of their 59 bars, which is 54 per cent. An oscillator bounded between 0 and 100 cannot express a drift; it can only express the balance of the last fourteen changes, and a mild upward balance parks the reading near 59, which is where this series’ median sits. Every extreme is then measured from a centre that is not 50. Anyone reading 70 as a distance above the middle is measuring from the wrong middle, by nine points, on a series whose whole vocabulary is forty-four points wide.

Thirteen readings, and what the tape was doing at each

Here are all thirteen overbought readings from the fourteen-bar simple version, with two columns beside each. The second is lesson 36’s efficiency ratio computed over the twenty bars ending at that same reading, which is knowable at the bar and repaints nothing. The third is what the price did over the next five bars.

BarReadingEfficiency ratio, prior 20 barsPrice five bars later
3775.30.012-1.3
3881.00.2740.0
3971.40.067+2.0
4370.10.426+3.0
4472.90.445+2.3
4577.90.445+1.1
4678.80.567+1.1
4780.00.587-0.7
4873.50.512+0.8
4973.50.519-0.1
5370.60.391-0.9
5476.20.333+0.4
5671.90.259no data

Read the second column first and the first column not at all. The reading itself tells you nothing: 81.0 at bar 38 is followed by no change whatever, and 70.1 at bar 43, the mildest reading in the table, is followed by the largest advance in it. Sort by the efficiency ratio instead and the table separates. Below 0.30 there are three readings with five bars behind them, and the price is higher after 1. At 0.30 and above there are nine, and the price is higher after 6, which is 33 per cent against 67.

That is the result the folklore predicts, and it is where almost every treatment of this stops. It should not, because the same split run on every bar rather than only the overbought ones gives 55 per cent below 0.30 and 67 per cent at or above. In the trending stretch the overbought readings return exactly what any bar returns. In the chop they return less than any bar does.

The regime is the signal. The oscillator is a slower way of saying it.

Which puts the honest version of the folklore two steps back from where it is usually left. It is not that an overbought reading means continuation in a trend and reversal in a range. It is that the reading contributes nothing on top of knowing which of the two you are in, and the thing that tells you which of the two you are in is a two-line calculation over the same window that the oscillator is already using. One of those numbers is a ratio of averaged gains to averaged losses, and the other is net travel over path length, and only the second one changed its answer between the two halves of this table.

What survives

Two things, and the first is only visible if you push the horizon out. Five bars after an overbought reading the price is higher on 7 of 12, which is the base rate to the digit. Ten bars after, it is higher on 9 of 10, which is 90 per cent against a base rate of 78. Nine observations is nothing to build on and the direction is worth naming anyway: on this series the reading everyone treats as a sell is followed by more upside than average, later rather than sooner, which is what you would expect of a statistic that fires when a trend is already established.

The second is the ratio itself, read as a description rather than a threshold. Fifty-eight point eight is this series’ average reading and 59.7 its median, and knowing that costs nothing and immediately fixes the level problem: on an instrument whose oscillator lives at 59, a print of 70 is eleven points of unusual rather than twenty. Compute your own instrument’s median reading once and every level you have ever been given moves.

What this does not settle

That twelve readings establish the regime split. They do not, and the split has a dial of its own that this page picked. At a threshold of 0.30 the two groups return 33 and 67 per cent. Move the threshold to 0.25 and they return 50 and 60; move it to 0.35 and they return 50 and 62. Three readings in the low group is a story rather than a measurement, and lesson 50 priced what separating two rates near these takes: hundreds of observations, not nine. The direction of the finding is the same at all three thresholds, which is the most that can honestly be claimed for it.

That the thirteen-against-zero transfers to your chart. The mechanism transfers exactly and the numbers do not. Wilder’s smoothing will always be later and narrower than a simple window of the same length, on every series, because that is what its weights are. Whether that narrowness is enough to stop it crossing 70 depends on how far the instrument runs, and on a genuinely trending market both versions cross. What this series shows is that the gap can be the whole distance between thirteen signals and none, which is enough to make the question worth asking of your own platform before the next trade rather than after it.

That the oscillator was tested in the form its users mean. This page tested one threshold on one construction at three periods and two smoothings, because that is the version that can be reproduced from printed numbers. The looser versions were not tested and some of them are better: divergence between the reading and the price, which lesson 34 counted and found to depend on a swing setting nobody prints; failure swings; crosses of the fifty line; levels of 80 and 20 rather than 70 and 30. Two of those are testable on this same series in an evening and this lesson did not test them.

That the efficiency ratio is a clean instrument for splitting the table. It is knowable at the bar and it repaints nothing, which is why it was used, and it is still a window measurement with lesson 38’s problem inside it: a twenty-bar reading belongs to those twenty bars and lesson 45 measured how far a window statistic can move when the window moves. The split above would look different under a fifteen-bar window or a thirty-bar one, and this page did not run those either. The column that turned out to be doing the work has the same disease as the column that was not.

That any of this tells you what to do when the reading is high. It tells you that the reading is not the thing to act on, and that the regime is, and it leaves the harder question standing: with twelve configurations of three ordinary indicators on a chart, most of them will agree with whatever you already think, and the ones that disagree are one setting away from being turned off. That is not a problem the arithmetic on this page can reach.

Problems

  1. Compute the oscillator twice and count the difference. Take sixty closes of one instrument. Compute the fourteen-bar reading with a simple average of the last fourteen gains and losses, then again with Wilder’s smoothing, which keeps a fourteenth of each new change and the rest of what it held. Count the readings above 70 under each. The difference between those two counts is the number of signals your platform’s choice of average created or destroyed for you, and you have never been shown it. Ten minutes.
  2. Put the outcome against the base rate on the same bars. For every reading above 70, record whether the price was higher five bars later. That is your hit rate. Then record the same thing for every bar in the series, overbought or not. That is your base rate. If the first is not clear of the second, the level told you nothing, and on the series in this lesson the two are equal to the digit. Half an hour.
  3. Split by a regime measure you can compute at the bar. For each reading above 70, compute lesson 36’s efficiency ratio over the twenty bars ending at that bar: net change divided by the sum of the absolute bar-to-bar changes. Sort your readings by it, split them at your instrument’s own median, and compute the five-bar hit rate in each half — and then compute the base rate in each half too, because that is the comparison this lesson turns on. Keep going until you have a hundred readings rather than twelve. An evening, and at the end you hold four numbers that settle for your instrument what a page of thirteen rows can only point at.

Sources. J. Welles Wilder Jr., New Concepts in Technical Trading Systems (Trend Research, 1978), for the original definition of the index and of the smoothing that produces the zero in the table above; the two fourteen-bar rows differ because one of them is his and the other is not. Richard W. Hamming, Digital Filters (Prentice-Hall, 1977), for delay as the first moment of a weight vector, which is where the 6.50 and the 13.00 come from and why the difference between the two smoothings is a fact about their weights rather than about markets. Andrew W. Lo, Harry Mamaysky and Jiang Wang, “Foundations of Technical Analysis: Computational Algorithms, Statistical Inference, and Empirical Implementation” (The Journal of Finance, 2000), for the discipline this lesson borrows: define the pattern precisely enough to count it, then compare what follows it against what follows everything else. Cheol-Ho Park and Scott H. Irwin, “What Do We Know About the Profitability of Technical Analysis?” (Journal of Economic Surveys, 2007), for the survey finding that results of this kind weaken as the tests get stricter, which is the direction the base-rate column above points in.

An oscillator is a ratio of averaged gains to averaged losses, bounded between 0 and 100, and every quarrel about what its levels mean is downstream of two choices nobody displays: how long the window is and which average smooths it. On this module’s sixty closes those two choices are the difference between thirteen sell signals and none. What survives is that the reading describes the balance of the last fourteen bars, that 70 is seven up bars in ten rather than an extreme, and that the regime you are in accounts for the whole of what follows. Lesson 52 takes the last step in this module and it is the uncomfortable one. Three indicators at four ordinary lookbacks make twelve configurations, and on 20 of the 39 bars where all twelve are defined one of them reads bullish while another reads bearish. On half the bars you can find a reading that says what you want, without doing anything a reasonable person would call cheating, and that is the problem no amount of arithmetic on a single indicator can solve.

Related Lessons
Lesson 50

Moving Averages as Support

The same question asked of the other line, and the 609 it would take to answer it.

Read Lesson →
Lesson 48

What an Indicator Is

Where 6.50 and 13.00 come from, and why a smoother filter is a later one.

Read Lesson →
Lesson 36

Markets Have Modes

The efficiency ratio that turns out to be doing the work in the table above.

Read Lesson →
Educational only. Trading involves substantial risk of loss. Not financial advice. Past performance does not guarantee future results.

💬 Discussion (0 comments)

0/1000

Loading comments...

← Previous Lesson Next Lesson →

Ready to Trade with Signal Pilot?

Apply your trading education with professional indicators and real-time market analysis tools.

Back to Signal Pilot →