Adaptive Trading Strategies

I think someone mentioned it already but it sounds like a bar-after-bar optimization method.

I'm not 100% confident that I understand what you mean by bar-after-bar. It is similar to the overlapping block approach (bad description I know) except the optimization period is always trailing the current bar, so all signals that are generated are out-of-sample. Naturally, this assumes that the parameter ranges have not been optimized using the data put aside for the trading simulation.

Let us consider a simple moving average crossover system: SMA(5) > SMA(30). Can you provide a backtest of the performance of the system with Dakota in action?

Did you have any securities in mind? I am happy to do some runs for you. Given that you have specified SMA(5) > SMA(30) I would set the parameter ranges for the first SMA from 2 to 8 and the second from 20 to 40 so that the system has the opportunity to adapt. Also, is this a long only system or do you want to go short when the shorter SMA crosses below the longer SMA?

Best Regards,

James
 
Quote from jalsck:

I'm not 100% confident that I understand what you mean by bar-after-bar. It is similar to the overlapping block approach (bad description I know) except the optimization period is always trailing the current bar, so all signals that are generated are out-of-sample. Naturally, this assumes that the parameter ranges have not been optimized using the data put aside for the trading simulation.

it is realy not that hard to understand why this aproach is considered to be optimizing rather than adapting. on this aproach of yours have systems been built allready, a tradestation system that sold for $5k from someone that i could provide his name later to you (i forgot it) comes to mind. his aproach was a socalled "selective optimizing". this system has failed tremendesly in realtime.

now dont get me wrong i am not saying that your performance cant be reached but you are looking back a certain amount of bars to find the best setting that would have gave you the highest performance during this period, this you do all by refering historical data and thus, you optimize (or adapt as you would like to call it) your strategy parameters to those market circumstaces givin in that period.

then the next bar or xx bars later you run this same aproach, look back, find parameters, adjust parameters and run next trade.

i doesnt get more optimized as in your aproach, and what you are doing can be done pretty much in every backtesting software, just not automaticly. that is the only difference imo.

pls explain what is the difference between you running your aproach or me brute force optimizing a tradestation strategy every bar to find the best parameters ?

dont get me wrong, i see how your performace is made out of walk-forward testing and i have no doubt your performace is real and *could be* achieved, but i am critizing your *aproach* and find it anything but adaptive.

i have no idea how one could call your aproach/strategy adaptive


EDIT: the name was dr clayburg
http://tinyurl.com/adaptive-or-not (i used tinyurl here because i feel people like him do not deserve free backlinks to promote their useless stuff)

from his website:
The Universal System is most effective when the system is selectively
optimized when necessary. Selective Optimization is a unique application
of commomly used optimization routines designed to keep the system in
sync with current market conditions.
 
Quote from flyingdutchmen:

dont get me wrong, i see how your performace is made out of walk-forward testing and i have no doubt your performace is real and *could be* achieved, but i am critizing your *aproach* and find it anything but adaptive

EDIT: i said that wrong, i am not even critizing your aproach, i know this aproach can work, more am i critizing the way you like to name it, which is *adaptive* rather than
*constant optimized*
cheers
 
it is realy not that hard to understand why this aproach is considered to be optimizing rather than adapting.

I was thinking that the term you used 'bar-after-bar' might have had some meaning that I wasn't familiar with. We are on the same page here.

now dont get me wrong i am not saying your performance cant be reached but you are look back a certain amount of bars to find the best setting that would have gave you the highest performance, this you do all by refering historical data and thus, you optimize (or adapt as you would like to call it) your strategy parameters.
This is accurate except I don't recommend using the best parameter values. Using the best parameter values is a very simple approach. The slightly more involved approach of using a set of trading bots and a applying some rules as to how they move within the parameter versus performance space does produce better results. How much better depends on the trading algorithm (indicators and rules). Some algorithms are relatively rigid and won't benefit much from adaptation because the model is making a lot of assumptions.

then the next bar or xx bars later you run this same aproach, look back find parameters adjust parameters run next trade.

This is done on a bar by bar basis as you have described.

i doesnt get more optimized as in your aproach, and what you are doing can be done pretty much in every backtesting software, just not automaticly. that is the only difference imo

I have been considering writing an adaptation engine for AmiBroker. The only barrier that I might face is that AmiBroker will process all bars when I load the system each day. If I am running 10 systems then it might take a substantial amount of time, maybe too long, to generate the signal for the next day. Dakota saves all data to disk every day and then only processes the new days data when the system is loaded again. I have written some indicator add-ins in C++ for AmiBroker, but I'm not that familiar with the app yet. Maybe I can find a way to save all data (indicator arrays etc.) to disk daily and then process one day at a time from then on.

pls explain what is the difference between you running your approach or me brute force optimizing tradestation every bar to find the best parameters ?

There will probably be a very significant difference. Every time I have tried using the best bot in the swarm it has produced significantly inferior results compared to the average of all bots in the swarm. This is not a 1 to 1 comparison because there are a few rules that determine how the bots will move within the parameter space. If you are willing to provide me with tradestation code that does as you describe then I will build an equivalent system in Dakota so that we can compare results.

i have no idea how one could call your approach/strategy adaptive

If a trader has noticed that the daily moves are strongly mean reverting and trades on that basis for say a few years until he notices that the opposite is now true (after a losing streak) and so he modifies his strategy accordingly then we would say that he has adapted to the change in that particular market regime. If a trading system basically does the same then I would say that the trading system has adapted. This is a simple and somewhat extreme example. There are numerous examples, should we be buying or selling new 3 day lows, 7 day lows or 10 days lows and should we take profits when the price exceeds a 3 day SMA, 5 day SMA etc.

A strictly non-adaptive trading model will never change it's parameter values and trading rules. It is written in stone and doomed. An adaptive trading model will change it's parameter values and trading rules in reaction to changes that have occurred in the market. A super smart model would predict changes in market regimes and adapt accordingly. Now that would be awesome.

To what degree a system is able to adapt depends very much on the model. Every model has built in assumptions and those assumptions can mean that the model will only work under certain general conditions no matter how wide the model parameters are set. It's not easy, at least I don't find it easy.

By the way, I no longer use short lookback periods for measuring trade bot performance. All of my current systems use a lookback period of 1,000 trading days. Also, I use as much historical data as possible to cover a good variety of market regimes on all time scales.

I think I have answered the question. In summary, an adaptive model is adaptive because it changes in reaction to changing market behavior. The ways in which a model can be changed depend on the model. I started this thread to discuss various and hopefully new ways to enable adaptation.

Regards,

James
 
What happens if you detrend the data and feed that to your model? The small edge is probably due to the slight trend in data. I don't see results that break down going long gains and going short gains.

Also, there is always a hidden curve fitting that people don't take into account - since these sorts of systems appear almost monthly in publications over the years, there is a kind of selection bias that it may have some edge. The only way to quantitatively take that into consideration is to punish a system every time you tried to develop a system on data you have seen or read an article on trading systems.

The value in a system like this may be as you stated as a system of systems, where this system could protect against strong trends (how did it do in Jan - May of this year and September to today ?), but that is only conjecture on my part since I have not done the study.
 
Quote from jalsck:

Did you have any securities in mind? I am happy to do some runs for you. Given that you have specified SMA(5) > SMA(30) I would set the parameter ranges for the first SMA from 2 to 8 and the second from 20 to 40 so that the system has the opportunity to adapt. Also, is this a long only system or do you want to go short when the shorter SMA crosses below the longer SMA?

Let us make this a stop & reverse system. You go long when 5 > 30 and short when 30 < 5. No other stops. Simple system.

For the purpose of being able to compare different approaches I suggest using this data file from 01/2002 for the Qs, daily data timeframe:

http://www.4shared.com/document/my0i1lo3/QQQQ.html

Everyone is welcome to compete here!
 
What happens if you detrend the data and feed that to your model? The small edge is probably due to the slight trend in data. I don't see results that break down going long gains and going short gains.

I have a price transformation routine setup accumulates the daily natural log return times 100 minus 0.0184. I will give it a spin, it will takes a while to run to completion. The trade report needs a lot of work. Reporting in terms of points is fairly useless over long time periods. I intend to report on Ln returns, remove some less useful stats and add-in CAGR etc. as well as the stats that you mentioned.

Also, there is always a hidden curve fitting that people don't take into account - since these sorts of systems appear almost monthly over the years in publications, there is a kind of selection bias that it may have some edge. The only way to quantitatively take that into consideration is to punish a system every time you tried to develop a system on data you have seen.

Great point. My personal awareness of hidden curve fitting traps has increased a lot over the last year or so and I am always on the lookout for more!

The value in a system like this may be as you stated as a system of systems, where this system could protect against strong trends (how did it do in Jan - May of this year and September to today ?), but that is only conjecture on my part since I have not done the study.

I will post the results when the run finishes. I think you are referring to the last one that I posted the details of on this forum, I can re-build any of them though. I was thinking that combining the system with intermediate and long-term systems would work well.

BTW I don't use any of the systems that I have posted the details of in production. I thought they were interesting systems because of the high dependence on the adaptation process.

Regards,

James
 
fwiw, i still do not agree with the name you have given the aproach, but the aproach itself i find a wonderfull thing if the calculating does not take to much time. i havent seen any retail platform with something similar yet, if i would want to do this i would need to optimize by hand every new bar to find out the suitable sets of parameter which would have givin me the greatest profit over xx bars for the upcoming trade. i am sure the average retail trader would make great use of it if a platform like tradestation would offer a similar aproach. for this you have my respect
 
Quote from flyingdutchmen: i havent seen any retail platform with something similar yet, i
Quote from jalsck:The following is a description of how adaptation is enabled in BioComp Dakota. The concepts can potentially be implemented using other software applications with some effort. There are many different ways to incorporate adaptation into a trading system. This post might provide others with some inspiration.

BioComp Dakota is a product of BioComp Systems Inc. BioComp Systems provide state of the art modeling, prediction and optimization technologies to corporations and individuals. Dakota is a stand-alone application for building trading systems. The Dakota application framework is flexible thereby, enabling trading systems developers to plug-in their own technical indicators / trading rules, performance engines and adaptation routines.
Flying:

See http://www.biocompsystems.com/products/Dakota/

BioComp products are not widely know but often receive honorable mention in the TASC annual survey (which, in my opinion, is primarily a popularity poll)

Jack
 
For interests sake I have attached a couple of images of the ARM03 run using the detrend S&P 500 data. It's only up to 1987 so far.
 

Attachments

Back
Top