October 19

13 comments

Multiplex For Greater Profit

By Curtis White

October 19, 2021

EasyLanguage, Multiplex

Two problems that often result from system optimization are: 

(1) a reduction in the number of trades, a system that generates too few trades can both be more difficult to trade and a low number of trades does not inspire confidence; and...

(2) there is a selectivity or specialization risk that, by sheer bad luck, the specific chosen parameter values will under perform in the future even while the basic system continues to work across most other parameters.

It is thought that hedge funds often run classes of similar systems to avoid the risk of simply choosing a set of unlucky parameters but individual futures traders may not have the capital to deploy a class of similar systems for essentially a single trading concept.

We present the concept of signal multiplexing as a method to increase the number of trades which offers the possibility of greater confidence and profits– while also providing the added bonus of reducing the specialization risk of trading a single parameter set. To demonstrate the concept, we build a RSI swing trading system for the ES but instead of optimizing for a single specific optimum: we optimize across three signals any of which can get us into or out of a trade. We chain the signals using conditional “OR statements”.

inputs:
RsiLength1(1),
RsiLength2(2),
RsiLength3(3),
RsiBuyThreshold1(30),
RsiBuyThreshold2(30),
RsiBuyThreshold3(30),
RsiSellThreshold1(70),
RsiSellThreshold2(70),
RsiSellThreshold3(70);

Value1 = Rsi(Close,RsiLength1);
Value2 = Rsi(Close,RsiLength2);
Value3 = Rsi(Close,RsiLength3);

If value1 cross under RsiBuyThreshold1 or value2 cross under RsiBuyThreshold2 or value3 cross under RsiBuyThreshold3 Then buy next bar at market;

If value1 cross over RsiSellThreshold1 or value2 cross over RsiSellThreshold2 or value3 cross over RsiSellThreshold3 Then sell next bar at market;

For comparison purposes, we compare the RSI 2 using standard settings against our computer optimized RSI Multiplex system.

RSI 2

RSI 2 Multiplex

Total Net Profit

$89,600

$133,925

Winning %

72%

69%

Profit Factor

1.59

1.93

#Trades

393

515

Average Trade Profit

$227

$260

Largest Winning

$4,512

$6,375

Largest Losing

$7,425

$6,612

RSI-2 Standard - Click For Larger Image

RSI-2 Multiplex - Click For Larger Image

We generate significantly greater total net profit, greater profit factor, more trades, increased the largest winning trade, reduced the largest losing trade, and smoothed the equity curve. 

Out-of-Sample Results

We held out the last 30% of data out-of-sample, and we can compare how the systems did during the out-of-sample period.

RSI-2 Standard - Click For Larger Image

RSI-2 Multiplex - Click For Larger Image

Our multiplexed system did significantly better during the out-of-sample period.

As a final sanity check, we also optimized a single entry and exit and the net profits were only $98,475 while the profit factor was 1.58: our Multiplexed system outperformed.

While in this case, the results from signal multiplexing were superior in every way, it is worth pointing out that even if the results weren’t the best, a multiplexed system could still do better in reality because of the benefits of diversification. In this case, we optimized across three entries and exits which were chosen somewhat arbitrarily but one could certainly optimize across even more signals.

One last check is due to being a long biased system, it is possible that simply being long more could have enhanced the results but even when looking at the short only results: we've seen greater short profits confirming the potential value for multiplexing signals.

Note: Because we used genetic optimization, your results may differ slightly from ours.

--by Curtis White from Beyond Backtesting

Curtis White

About the author

Hi, I'm Curtis and I'm passionate about markets and trading.

My mission is to apply machine learning to build better trading systems and to become a better discretionary trader by applying quantitative and machine learning techniques to solve my greatest trading problems. I develop trading systems and graybox trading solutions using Tradestation's Easylanguage, Python, C#, and Ninjatrader.

  • Out of sample results for the past 3 years for a long only system in a raging bull market is hardly “proof” that this concept works. I would argue that such an out of sample is useless. Add on to that the fact that results are from genetic optimization, and my conclusion is a nice curve fitted overoptimized system with a meaningless out of sample period. Can the author provide the parameter settings for each of the 2 cases, and then at least the 2 systems can be monitored in real time? Maybe then in 6 months this article can be revisited whilst we wait. Cheers mate.

  • OK, we agree – take away the out of sample “verification” – it is useless in this situation. After that what are you left with? System 1 is simple – 3 optimized variables. On the other hand, System 2 is 3 times as complicated – 9 optimized variables.

    Everyone should easily recognize that when you optimize both of these, System 2 is going to have better performance numbers – it has 6 extra optimized variables, after all.

  • @Simon Excellent point. I would point out I did verify the short results, as well and mentioned that but I did not post them.

    I would also like to point out that the conjecture is defacto true. The objective is to obtain a “closer proximity” to the overall performance which would be an average of all parameter values. So, in that respect it is defacto true. Now, if your system relies on an “optimal parameter” setting then you wouldn’t be attempting to capture the “class” of system performance.

    I should also point that if you could pick the true optimal that this method is likely to yield lower results because the goal is to diversify across all the settings. The idea is basically right in any given year if you took a basket of all trend following strategies and averaged them out that you’d probably come up with the typical result for traders following those sorts of strategies. There’d be some outliers who hit it real good and some who did really poorly. But, this is about capturing the “average” gain.

    The word multiplex means to basically overload a signal. But, yep these are just ideas: keep questioning my work and thinking about it.

  • Thanks but whilst “the goal is to diversify across all the settings,” you certainly have not done that. You have not diversified, you have optimized. If you really diversified, I would expect your “average” system performance to be worse than your optimized System 1. Your approach has created something better than the already optimized System 1, and it is because you changed the system, and you are curve fitting and optimizing more.

    So you have taken optimized results of System 1 and made them even more optimized with System 2. This is 180 degrees from what you wanted to do, which was to find the average performance of the RSI strategy.

  • Just to be clear, I realize you personally may not have an optimized the Strategy #1 (RSI(2)), but somewhere down the line that was optimized (hence the setting of 2, which is not standard with original RSI). Since it was optimized, I’d expect the average RSI system performance to be worse than the optimized Strategy #1 shown, hence my earlier comment. Sorry that I was not clear on this.

  • @Simon

    Right, we are optimizing but instead of picking a single optimal value, we are picking multiple optimal values that work well together. A parameter is anything that can vary, right. So, if you pick any RSI length then you are introducing an arbitrary parameter. If you optimize, you are picking the single best parameter. Instead of picking the single best parameter, this method selects the Nth top parameters that combine well together. There is this hidden combination factor which makes it not quite like diversifying, and might be the best part, but the fact we are trading multiple parameters does reduce the selection risk.

  • Reducing selection risk is a good idea, I agree. I just do not think what you did actually decreased that risk. I think you actually increased selection risk, by adding more variables and running excessive optimization. But who am I to say?

  • Correct me if I am wrong but it may be wrong to say the author is over optimizing. It is my understanding that the author is optimizing one time and then picking three different set of parameters that performed, not the best but good, and applying the signals to one strategy. Sometimes I’m sure the signals would agree with each other and sometimes the short would cancel out the long signal. This would be a way to diversify the signals of a simple system. I will test this theory out on my next strategy. Great article!

    I have had a similar idea but not exactly. Basically in my optimization I have often thought the picking the best set of parameters for say the last 2 years is hardly likely to be the best moving forward so maybe picking an average stable winner in a field of winners would be a better strategy moving forward. Previously I had thought to still pick one set of Parameters but this multiplexing idea would allow a bit more diversity in your choice.

  • It seems to be an only long strategy. One can see the equity curve
    of the results , but not the price chart to which the strategy was applied.
    Will it work in a bearish trend as well ?

  • {"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}

    Learn To Code & Build Strategies
    Using EasyLanguage. 

    >