indicator · own pane · open source

Awesome Oscillator

Deepwick · @deepwickv1Updated 2 Oct 2026▲ 0 users
Running…
Loading chart…

About

Awesome Oscillator (AO) is the difference between the 5-bar and 34-bar SMA of the mid-price (hlc3). The classic Bill Williams momentum histogram.

  • Twin peaks above zero = strong bullish momentum.
  • Twin valleys below zero = strong bearish momentum.
  • Pair with the Accelerator Oscillator for confirmation.

Source code

//@version=5
indicator("Awesome Oscillator", overlay=false)
fast = input.int(5, "Fast Length", minval=2, maxval=50)
slow = input.int(34, "Slow Length", minval=2, maxval=200)
ao = ta.sma(hlc3, fast) - ta.sma(hlc3, slow)
hline(0, "Zero", color=color.gray, linestyle=hline.style_dotted)
p_AO = plot(ao, "AO", color=ao >= 0 ? color.green : color.red, style=plot.style_columns)
alertcondition(ta.crossover(ao, 0), "AO crosses zero up", "Awesome Oscillator crossed above zero")
alertcondition(ta.crossunder(ao, 0), "AO crosses zero down", "Awesome Oscillator crossed below zero")

Comments

No comments yet.

Sign in to comment.