Internal Bar Strength (IBS) Trading Strategy In Consumer Staples (XLP)

Last Updated on June 19, 2022

The internal bar strength is defined as follows: (close-low)/(high-low). This indicator is very useful on mean revertive trading instruments, like for example XLP.

This article contains a simple but quite effective trading strategy using the internal bar strength indicator:

The internal bar strength trading strategy

In plain English the strategy is like this:

  • Yesterday’s IBS must be lower than 0.15.
  • Today’s IBS must be lower than 0.4.
  • RSI(5) today must be lower than 50.
  • Entry on the close.
  • Exit when today’s close is higher than yesterday’s high.

The strategy is tested on the ETF with the ticker code XLP, an ETF that tracks the major consumer staples.

Here is the equity curve:

2008 was actually by far the best year:

And here are all the trade details:

When testing for optimization there is a clear pattern that it’s best with a low IBS yesterday and a bit higher today.

Of course, the annual return is pretty low, but that is because the strategy spends most of the time on the sidelines. The strategy spends about 505 days in the market over this period, only around 16% of the trading days.

———————

If you would like to have the Amibroker and Tradestation code for this strategy plus 70+ other free trading strategies published on this website, please click on this link:

For more trading strategies, please click here:

 

 

 

Similar Posts

  • Thanks Oddmund for sharing.

    Q. Have you given up using excel and now are using Amibroker instead?

    I recall you were always a fan of excel.

  • Hi Oddmund,

    any reason why this was tested on the XLP only ? as %

    exposure is quite low, why not create a portfolio strategy
    with other sectors/indexes? plus the sharpe looks good, introducing some leverage here would boost the
    return without introducing excessive volatility into the strategy.

    Cheers
    Ray

    • Different ETFs/market have different attributes – they behave differently. I would certainly not reject any idea because it does not fit all markets. This has served me well for 20 years.

      This test is just one of 1000s i test. In XLP alone I currently have 7 different strategies i trade.

  • Hi Oddmund,

    a) You decide to test Internal Bar Strength and look for instruments where you could find a way out

    OR

    b) You look at Consumer Staples and test a bunch of indicators and systems to select the ones that stick.

    What is your research process usually: a) or b) or else ?

    Take care,
    Candide

    • I usually do a mix of both. I admit there is a degree of curve fitting, but i try to papertrade every strategy some months before i go live so i get some kind of confirmation. It’s very easy to just look at the end result and say all is good, but it’s only when you have a position you can see (and feel) how it works. So far this has served me well. Personally i think the clue is to have a lot of strategies.

      This article explains how 2 non optimal strategies works well with other non-optimal strategies:
      https://www.investiquant.com/cms/wp-content/uploads/2016/12/InvestiQuant-Primer.pdf

  • Hi. There has been some evidence that IBS indicator has deteriorated in recent days, especially on the indexes. Do you feel the same happened for individual stocks you trade?