Why you should be careful with a stop-loss that is too small

In the past, I have put several traders who experienced completely different live results from their backtest results. The cause was an apparent triviality: too small a stop-loss. Let me explain to you today why this can be a problem, what you should be aware of, and how to avoid this danger. The following topic is only about those breakout strategies that use the STOP order to open a position and at the same time use too small a stop-loss (this article is not about strategies that use the market order). What is a stop-loss that is too small? Well, it depends on the market and the time frame. But in general, it is a smaller stop-loss than the size of an average bar of our main time frame. Let me give you an example: if we are using a 30 minute chart with an average bar value of $250, and our strategy works with a stop loss of $80, we are heading for serious trouble. Live trading results can (and in most cases almost probably will) be totally different from what we get backtested. Let’s take a look at the reason why.

This problem occurs when the stop-loss is so small that some of the trades have order entry and stop-loss on the same bar. Let’s say we have a STOP entry order at price 100 and also a stop loss at price 99. Now imagine the bar opens at 98.7, goes to 100.1 and we open the long position, and the stop loss is set at 99. And all this happens within the same bar, that is, within this single bar the entry order is triggered, the position is opened and the stop loss is set.

Now it is important to understand why this can be a potentially dangerous problem. It’s pretty simple. There are several backtesting platforms that are not able to recognize, with incorrect settings or when the data resolution is not good enough, whether or not the stop-loss was hit on an entry bar. In other words, there are certain situations where the stop-loss was actually hit right after the position was opened, because right after the entry order is triggered, the market starts moving south. However, our backtesting platform assesses the trade as profitable (from now on I will write about TradeStation as it is a platform I mainly use). How is it possible?

Let’s continue with the proof of the situation described above. In this situation we can see the rising bar, that is, the one with a closing price above the opening price and, at the same time, the closing is close to its maximum.

TradeStation simply follows the logic that when the bar closed near its high, the process of generating this bar was increasing. In such a situation, TradeStation assumes that the bar opened at 98.7 and the price continued to rise to 100.4. And during this time, it also triggered our buy order at price 100.

However, this is a very inaccurate and dangerous assumption. What if the bar was going up first, you triggered our buy order, but then it reversed back down, below our stop loss, and then started up again to close your high?

This is a totally realistic scenario that happens every day that would result in a clear loss (right after we opened the position) and yet TradeStation (and potentially other software as well) defines the situation as no intra-bar correction. So no stop loss was hit and the trade ended up being profitable. This is the main cause of the main problems, as in the backtest you clearly see many profitable trades that would actually end in losses, and right after we start trading this strategy live, everything starts to fall apart…

Protection #1

Luckily the situation is not as serious as it seems and backtesting platforms generally take this risk into account.

The first protection against this threat is simple and, to some extent, highly efficient. TradeStation calls it LIBB (Look-Inside-Bar-Backtesting), others call it by other names, such as Bar Magnifier. The point is that when you activate this function, the program looks inside the bar at the level of the finest data resolution available (in most cases it is 1 minute), if there was no internal correction after the entry order was triggered, or if there was a correction on the same bar when we entered and the stop-loss was reached.

Although it sounds like a great solution (which is a standard part of most platforms these days), it doesn’t have to be enough when it comes to small stop-loss. Because? Imagine a situation where your stop-loss is $80, but the average bar of your best LIBB resolution (ie mostly 1 minute) is $150. In this case, you are experiencing the same problem as described above, when the platform cannot determine whether the stop-loss inside the bar was hit or not and makes, again, only inaccurate guesses that are driven by the logic described above: whether the bar closed closer to its low or closer to its high. In other words, you are back to the beginning and with too small a stop-loss, even LIBB will not help you, and the problem persists.

Protection #2

So, we’re getting to the point where we need to dig a little deeper to solve this problem. But this is not as easy as it seems. First of all, historical tick data is not as easily accessible, or only for a very short period. And if this data is available, it is really expensive. But even if you still buy tick data, you have to work out various technical issues, as tick data is usually so big that most platforms won’t handle that much data, fail, or run incredibly slow backtests (I can confirm this).

Protection #3

So we need to use a much simpler solution, and that is the need to use a reasonably large stop loss. And what is a reasonably large stop-loss? Just use a stop loss that is at least 1.5-2x larger than the largest 1 minute bar on your chart. It is simple and you can avoid several problems. For example, if the largest 1-minute bar for all of your data history was $300, use a stop loss of at least $450. Spot. It is simpler and safer to get used to higher stop-loss than to lie to ourselves and subsequently be surprised why such a nice backtest equity is the complete opposite of live trading results.

Happy trading!

Leave a Reply

Your email address will not be published. Required fields are marked *