fbpx

Know how much edge your trading strategy has [SCIENTIFIC APPROACH]

Blog

Know how much edge your trading strategy has [SCIENTIFIC…

You must have an edge in the market… Use this thing and get more edge… This signal gives you the edge… Blabla edge blah…
We all heard it… We all kind of have an idea of what it is… And we all want it! EDGE! Ok well, but what is this magical edge? Well basically it’s just a fancy way of saying a statistical advantage. When you win 51% of the time it’s that 1% over the 50 that is your edge. When you do the same thing for long enough the edge is what actually makes you money. A casino always has the edge over the gamblers, and like so you want to get this edge over the markets when you trade.


Don’t like reading? Watch the video instead!


Well to get that statistical advantage you can do whatever – analyze the company’s financials before investing, use a fancy new strategy from the internets or anything else you feel works. But the question I have is HOW DO YOU KNOW IF YOU ACTUALLY HAVE THE EDGE? Does trading moving average crossovers gives you an edge? How about trading based on the lucky card draw? Well lucky for you this is where we find out!

And of course, this is a place of science for traders, so we will use statistics and math to do it.
So before we get down to business lets think a bit of how we should approach this, let’s call it “edge evaluation process”. Now if you have a trading track record of trades – you can simply go over your trades and see if they are making money in more cases than they are losing money. And it doesn’t matter if you do 10 losing trades and 1 profitable, or 2 winners 1 loser. As long as you do it consistently and making money you are good. So by looking at your past performance, you can see if your trading has edge.

Now a very interesting concept is actually that for some reason we always measure if our entry signals have edge. But if you think about it – trade is only as good as your entry and exit combined. You may have a killer entry signal but if you exit the trade late you might not make use of that killer entry signal at all. So here’s the interesting part – we can never evaluate the edge just of an entry signal alone. A trade is two parts and we need to evaluate them together. And I have the formula to do just that – even if you don’t have an exit signal. The beauty of this formula is that it tells you how your edge evolves after entering the trade. So you may find that your entry signal has a killer edge for the first few days of a trade and then it just turns south. Or you may find that your signals have a great edge over the long period but the first few days or weeks might be rather crappy. So let’s look at what I’m talking about here and let’s get into the formula of how you can calculate this yourself.
Real quick before we get to the math I just want to show you what the result we are trying to achieve here looks like.

Here you see a chart of the edge evolvement over time in trade for a strategy I have just backtested on my Diamond Strategies software. This chart shows what is the expected average edge for this tested strategy and tested trading portfolio for each bar we are in a trade. A value of more than 1 means that on average your trade is more likely to move in a favorable direction at the given bar and less than 1 means it’s more likely that your trade will move into the losing direction.

Now I hear you – Diamond, but you have this fancy software painting all these charts for you. What about us? Well, worry not, I will be doing the calculations in an excel spreadsheet and I will share that spreadsheet with you here. Moreso, I am working hard on making this software available to the public so make sure to subscribe to our newsletter or to the Statistical Trader YouTube channel to not miss any updates if you are interested.

Now let’s get to the math. Ok, so, as usual, you will need a list of past or hypothetical trades that you want to evaluate. We will be calculating the excursions of these trades on each bar. Now an excursion is a movement from the entry price to one or another direction. So we will be calculating the maximum favorable excursions a.k.a. MFE (movements that go in the profitable direction) and maximum adverse excursions a.k.a. MAE (movements that go in the losing direction) for each bar that we are in a trade since the entry point. So let’s start just with that.

I have run a backtest here, so I have a list of sample trades. Now, let’s take a few trades and manually calculate the maximum favorable and adverse excursions of those trades just to see how it’s done. Now make sure to calculate these values for each bar in the trade and write them down somewhere. Here I’ll be using a spreadsheet. And as I said you can download this spreadsheet HERE.

You can find all the formulas in the spreadsheet. But the idea is to get the bar values of the trade, entry and close values of the trade. And then you calculate the MAE and MFE values using the following formulas for each bar.

Now that we have some excursions to work with we are going to calculate the edge of these trades. As I said before, the edge depends on where you enter and exit the trade. So we will calculate the moving edge over the time you are in the trade and see how it evolves. To make this happen we will look at the MFE and MAE values of all the trades we have. Now the problem with this is that if you have trades of different instruments in your list this will not work if we use the plain values. Just because the prices of the instruments can vary drastically, so if we take an expensive stock and have its MFE be 10$, the MFE of a cheap stock might be just 1$.

So what we are going to do here is normalize all the excursion values by the ATR value of the entry point. Now you can choose the ATR period you like, or you can simply normalize it by the entry price itself and simply have % values of excursions instead of actual monetary values. I like to use ATR 7 just because it has been proven to work well statistically and because it also eliminates the factor of volatility. So we normalize everything simply by dividing the excursion value by the ATR value. Now we take the normalized values of the trades we have and we get the average normalized favorable and adverse excursion values for each bar throughout all the trades. Now naturally you will have some trades that you were in longer than the others. It is ok, just keep in mind that a statistical relevance of the edge value that has fewer trades in the calculation will be lesser than the one that has more trades. So now that you have all the MFE and MAE values for all your trades normalized and averaged out per bar – we can now calculate the edge. And you do that by simply dividing the MFE by negative MAE value.

You will get a value anywhere from 0 to whatever. Now, this value means how many times your favorable move per bar is higher than your adverse move. So if your values are more than 1 – you have the edge. Less than 1 means you don’t have edge and your trades move further down than up.

So here you have it!

Now one more thing – you remember I said you can even calculate this if you don’t have the exit signal? Well, all you do here is simply calculate this for as many bars after entering as you like and there you go. This might even be a great indicator of when you are most likely to make the most money if you exit your trades based on time. You might plot a chart for the edge values in excel and see that your edge goes up until day 2 in the trade and then crashes down. So you know exiting the trade after 2 days is the best time to do so.


There are a lot of use cases for this, you may improve your strategy by only letting your trade play out during a certain timespan and if it does not reach the stop or the target by that time you simply kill the trade on the best day.

So here you have it, traders. A statistical evaluation of how much edge your signals actually have. I hope you find a good way to use this to make your trading better. As always – if you want to join the community of traders that trade using science – make sure to subscribe our newsletter or to the Statistical Trader YouTube channel.

And please if you come up with creative ways to use this – comment down bellow or under the video!

 

Avatar
Diamond Zemaitis
Founder of Diamond Strategies and Statistical Trader 📈 Trader 👨‍💻 Coder 🛫 Digital nomad 👫 Husband 🌱 Vegan 😼 Cat dad | Follow me on IG @zemdei