Williams %R


Williams %R Strategy is based on reversal prospect indicator wrought by L.R. Williams. The basic idea standing beyond this indicator is to point if some security is overbought or oversold.

Indicator is calculated basing on transaction prices from some overwatched Period. Length of a Period can be adjusted to day trading or longer term strategies. Shorter Period effects with more rapid, but sometimes less reliable indicator changes.

Basic equation of the indicator is:

%R =
\frac{Max~period~price - Current~price}{Max~period~price - Min~period~price}
\cdot (-100)

General information obtained from it is a security current value ratio to the highest one in overwatched period. Indicator’s value falls within [-100, 0]. When strategy has no opened positions, value falls into one of margins established by Marginopen and then leaves it - that is a signal to open proper positions:

  • \%R leaves [-100, -100 + Margin_{open}] \rightarrow algorithm opens long position, security is oversold.
  • \%R leaves [-Margin_{open}, 0] \rightarrow algorithm opens short position, security is overbought.

Algorithm closes its position when the %R indicator crosses -100 + Marginclose or Marginclose. Also, there exists wide range of emergency brakes that may close position to prevent strategy’s loss. More elaborated version of this strategy can make position open/close signals and volumes dependent on further indicators and market conditions. To decrease number of false signals - price trend filters and more elaborated algorithms can be used.

Originally postponed Marginopen value, beyond which reversal of security trend is going to occur, is equal to 20% of indicator value range. Marginclose usually varies from 30% up, depending on accepted risk and expected profit.

Market Data

  • Last trade
  • Order book (1st level)


Parameter name Description Essential
Marginopen Margin of critical indicator value, beyond which strategy starts trading (%) Yes
Marginclose Margin of indicator value, which cross is signal to close opened positions (%) Yes
Period Length Length of an overwatched Period Yes
Order Volume Volume of single opened position Yes


Open position

Side Buy or Sell
Amount Order Volume
Price Last market price
Type Price limit

When Williams %R indicator value leaves one of margins set up either by -100 + Marginopen or Marginopen.

Close position

When strategy has any opened positions and Williams %R indicator crosses -100 + Marginclose or Marginclose. Also, a protection close might invoked by watchdog detecting potential loss.


There is no strategy termination condition.

Time frame

Strategy bases on some initial Period of data collection without trading and is designed to enable adjusting both: period of data collection and its trading time span from hours to whole weeks.

Further information & source

PLEASE NOTE: Empirica does not provide tax, investment, or financial services. The information available through this website is provided on an "as is" basis at user's sole risk and does not constitute trading advice or a solicitation to buy or sell any stock, option, future, commodity, or forex product. Empirica makes no guarantees as to the accurateness, quality, or completeness of the information and shall not be responsible or liable for any errors, omissions, inaccuracies in the information or for any user's reliance on the information. User is solely responsible for verifying the information as being appropriate for user's personal use, including without limitation, seeking the advice of a qualified professional regarding any specific financial questions a user may have. Past performance is not necessarily an indication of future performance. Trading is inherently risky.