Williams %R Trading Strategy – Williams Percent Range vs RSI (Indicator & Systems)

Last Updated on May 28, 2023

Williams %R was developed by the famous trader and tax rebellion Larry Williams, who has given names to several technical indicators. Last week we wrote about the WilliamsVixFix indicator, and today we are explaining the Williams %R trading strategy and how to calculate and use the indicator.

Williams %R does work. In this article, we explain how to use Williams %R in a trading strategy, and finally, we backtest trading strategies to see if Williams %R works. Does it work? Our conclusion is that Williams %R seems to work pretty well.

What is the Williams %R indicator?

The Williams %R fluctuates between 0 to -100. It’s an oscillating indicator and reflects the current close relative to the highest high for the lookback period.

The indicator is somewhat similar to the stochastic indicator, however, that one measures the close relative to the lowest low. A high reading is considered overbought, and low readings are considered oversold.

Here is how a 5-day lookback period looks in the S&P 500:

Williams %R trading strategy

Williams %R goes quickly from overbought and oversold conditions. Thus, it is mainly used as a mean reversion indicator.

How do you calculate the Williams %R indicator?

If you use a lookback period of five days the formula looks like this:

Williams %R = (  ( highest high last 5 days – close ) / ( highest high last 5 days – lowest low last 5 days)  )* -100

For example:

If the close today is 100, the highest high over the last five days was 115, and the lowest low over the last five days was 95, then the Williams %R is -75 ( (15/20) *-100 )

Williams %R resembles WilliamsVixFix

The Williams %R is pretty similar to the WilliamsVixFix (but inversely from each other). The chart below is both indicators using a 22-day lookback period:

Williams %R trading strategy backtest

Williams %R – does it work? We test some strategies

We test the Williams %R trading strategy on the S&P 500 (SPY). Entry is on the close when the Williams %R is below -90 and exit is when today’s close is higher than yesterday’s high or when the Williams %R closes above -30.

By using optimization we get, perhaps as expected, the best results on short lookback periods. We used a minimum lookback period of two days and a maximum of 25 days. All tests gave a profit factor of two or more, except for 25 days which produced 1.9.

The best result is by using a two-day lookback period. This gives this equity curve:

Williams %R trading strategy settings

Both during the GFC in 2008/09 and the Covid-19, the strategy performed exceptionally well. The percentage return in 2008 and 2020 were 98.9% and 43.3%!

The returns above are compounded. CAGR is 12.4% (buy and hold is 6.5%), exposure is 23%, the number of trades is 397, average gain per trade is 0.64%, max drawdown is 17%, and the profit factor is 2.36. These are pretty good numbers!

Does the Williams %R work for shorts?

Unfortunately, and as expected, it’s much more difficult to find profitable strategies on the short side.

Williams %R Amibroker code

If you would like the Williams %R code for Amibroker you can order it at the link below. Additionally, you get the code for all the other free trading strategies we have published:

Williams %R vs. RSI: we test different trading strategies

What is the best indicator: Williams %R or the RSI indicator?

The Williams %R is a mean revertive indicator, just like the Relative Strength Indicator (RSI) and Stochastics. Let’s test a trading strategy based on the RSI which is quite similar criteria as we did above for the Williams %R:

  • Enter on the close when the two-day RSI is below 10
  • Exit on the close when the close is higher than yesterday’s high or when the RSI(2) ends higher than 70

These criteria yield this equity curve:

Williams %R trading strategy trading rules

The CAGR is substantially lower than for the Williams %R: 6.23% vs 12.4%. Thus, the Williams %R seems to work better for the S&P 500 than the RSI.

Of course, the difference could be entirely due to chance and randomness. However, we suggest traders should test their RSI strategies and see if they can improve them by using Williams %R.

Williams %R works perfectly with this indicator

We changed the settings somewhat to test another strategy that included a second indicator and we got this equity curve on Nasdaq/QQQ (logarithmic):

Williams %R trading strategy backtest

The CAGR is 14.6% (buy and hold is 6.4%), the time spent in the market is 14.2%, 215 trades, 79% winners, the average winner is 2.35%, the average loser is 2.21%, the profit factor is 3.53, max drawdown is 20.5%, and the Sharpe Ratio is 3.16.

Would you like to know the code and the criteria (in Amibroker/Tradestation and plain English)? You can either order the strategy by clicking the link below, or you can subscribe to our Trading Edges. You can order the strategy on this link (please choose Williams %R Strategy No. 3):

BUY NOW

When you have paid, please press the link below to access the code (PDF file):

Download the Williams %R strategy no. 3 by clicking here (you need to pay for access)

Alternatively, you can subscribe to our Trading Edges where we send out ideas like this monthly for a lower fee per edge. The edge above will be presented as an edge in a few months. If you’d like to receive similar ideas, please subscribe to our Trading Edges:

Conclusion: Williams %R does work

The Williams %R trading strategies are pretty similar to the WilliamsVixFix. However, it seems like the Williams %R performs slightly better in our backtests. Moreover, on a wide range of backtests, Williams %R seems to perform better than both the RSI and Stochastics in the strategies we tested.

We believe the Williams %R is an underappreciated indicator!

Similar Posts

  • If the trading signal uses end of day data that is sent to your Amibroker after the close, how do you enter a buy order at the close?

    This is a genuine question that has been bugging me about system trading. I have seen other back tested systems that show the results as entering at the open or the close of the next day after the signal which degrades the profitability of said system.