Click here to Login




Why backtesting and optimizing a trading system is so important

Updated on 2012-09-28 by Guest







Before I get started, I need to explain what a trading system is. It is basically a set of certain parameters (rules) that establish points of entry and exit for a particular equity. These points are identified as signals and are used to buy or short a position.

The main reason to implement a trading system is to take the emotion out of the equation in trading and to save time. Human inefficiencies and second guessing loss-making decisions reduce profits a great deal. An effective trading system is automated and this will lead to increased profits and a lot of time saved for a trader. However, trading systems are not easy to adopt and it is important to set the parameters correctly and have a good understanding of what they are. This is where backtesting and optimizing a trading system come in.

Backtesting and optimizing a trading system go hand in hand and they can improve the results of a trading system. Backtesting and optimizing a trading system have their limitations with the main one being that past performance is no guarantee of future success.

For instance, if a trader wishes to test an approach that is grounded on the idea that internet IPOs do better than the market as a whole. This test would have different results depending on the time period that you chose. The dot-com bubble of the 90s would see that internet IPOs outperformed the market considerably. But this is not the case when the bubble burst, which showed poor returns as expected.

The good thing about backtesting is that it saves money. Investors can learn from mistakes that were made in the past without having to lose real money. The point is to gather information about the susceptibilities of a strategy via a computer-generated interaction with real-world conditions in an earlier period. It used to cost a pretty penny to get the necessary data sets and that was why only institutional investors and professional money managers had the luxury of performing backtesting. However, electronic trading has changed all that. Online databases are accessible to everyday traders and it is a feature that is available in an online brokerage account nowadays.

Users of backtesting are able to get valuable insights on how a trading strategy would have done had it been implemented in a prior situation. Optimizing a trading system involves looking for the finest parameter sets for a market situation. Backtesting is done to see how changing parameter values can lead to the highest performance and then applying these into the trading system.

An example will always be enlightening and so why don't we look at one. An investor might feel that he or she could utilize a daily chart to optimize the system after examining the S&P 500. But there could be more details implemented in this process. For instance, a moving average (MA)- crossover strategy could be used in a particular market and if a simple MA of 7 performs better than 9, in that case 7 will be the value of the perimeter.

But here lies the big problem and the reason why optimizing a trading system should be used carefully. It ignores market dynamics that are common occurrences and specific parameters will lead to instability when the market does inevitably change.

However, backtesting is a very important process in a trading system. The primary reason traders do a lot of backtesting is to prepare them for the worst that could possibly happen. Thorough backtesting will reveal holes in the trading system such as a possible prolonged drawdown or a continuous losing streak that could cost you $20,000.

The ability to interpret the results of backtesting and evaluate them properly is important as well. The way this is done is to look at a variety of things and not just the highest net return or a high profit per trade. The winning percentage, number of trades, average trade, consecutive losers, distribution of returns, the biggest winner and the biggest loser are some of the other factors that should be looked at.

In the backtesting process, find out how you can get the system to reveal its flaws if decent results are shown. There should be sufficient trades to test it well and you must be practical about slippage and other trading costs. Curve fitting which involves matching a trading system to the dataset is another issue that should be addressed in backtesting. At the same time, you should not look to go overboard with optimizing a trading system as it will make it less prone to function effectively in the future.

Trading software programs like QuantShare optimizes a trading system for you. But remember that there will never be a perfect one. As long as the parameters work well over a range, the trading system is good. If the 10-, 12-, and 16-period moving averages are superior in comparison to the rest, take the 14-period one. If the trading system works well for the 10-, 12- and 16-period ones and did not do so for the 14-period average, then there is something wrong with it. Basically, the trading system should perform well regardless of the moving average, which could be 6, 8, 10, or 12 periods.

In the same way, when optimizing a trading system with data from a certain stock like Microsoft, it is good to do backtesting with other stocks such as Coca-Cola, Intel, Wells Fargo, the Dow 30 and the S&P 500 index. These were all large firm stocks and it is important to have smaller stocks as well. Additionally, find stocks that are trending differently whether up, down or sideways. All types of market conditions should be used in the backtesting such as flat markets, volatile markets, downtrends and up trends.

The key takeaway is that backtesting and optimizing a trading system can produce very good results if they are done correctly.









comments powered by Disqus
Users Blog
QuantShare
Recent Posts

Types of Coupon Swap Futures
Posted 2313 days ago

How to Manage Capital Effectively?
Posted 2313 days ago

Trading With E-Mini Index Futures
Posted 2319 days ago

Impact of Economy on Stock Market
Posted 2330 days ago

A Primer on Day Trading Strategies
Posted 2456 days ago

A Closer Look at Insider Trading
Posted 2505 days ago

Seasonality in the Stock Market
Posted 2534 days ago

An Introduction to Paper Trading
Posted 2539 days ago

QuantShare
Previous Posts

A Primer on ETF Trading
Posted 2547 days ago

Is it too late to buy AAPL?
Posted 2547 days ago


More Posts

Back







QuantShare
Product
QuantShare
Features
Create an account
Affiliate Program
Support
Contact Us
Trading Forum
How-to Lessons
Manual
Company
About Us
Privacy
Terms of Use

Copyright © 2019 QuantShare.com
Social Media
Follow us on Facebook
Twitter Follow us on Twitter
Google+
Follow us on Google+
RSS Trading Items



Trading financial instruments, including foreign exchange on margin, carries a high level of risk and is not suitable for all investors. The high degree of leverage can work against you as well as for you. Before deciding to invest in financial instruments or foreign exchange you should carefully consider your investment objectives, level of experience, and risk appetite. The possibility exists that you could sustain a loss of some or all of your initial investment and therefore you should not invest money that you cannot afford to lose. You should be aware of all the risks associated with trading and seek advice from an independent financial advisor if you have any doubts.