Trading Systems: Constructing A System
  1. Trading Systems: Introduction
  2. Trading Systems: What Is A Trading System?
  3. Trading Systems: Designing Your System - Part 1
  4. Trading Systems: Designing Your System - Part 2
  5. Trading Systems: Constructing A System
  6. Trading Systems: Troubleshooting And Optimization
  7. Trading Systems: Conclusion

Trading Systems: Constructing A System

So far, we have discussed the basic components of trading systems, the criteria they have to meet, and some of the many empirical decisions that a system designer must make. In this section, we will examine the process of constructing a trading system, the considerations that need to be made, and some key points to remember.

The Six-Step System Construction

1. Setup - To begin constructing a trading system you will need several things:

  • Data - Because the system designer must use extensive backtesting, past price history is essential to constructing a trading system. Such data can be integrated into trading system development software, or as a separate data feed. Live data is often provided for a monthly fee while aged data can be obtained for free.

  • Software - Although it is possible to develop a trading system without software, it is highly impractical. Ever since the late '90s, software has become an integral part of building trading systems. Some common features enable the trader to do the following:

    • Automatically place trades - This often requires permission from the broker's end because a constant connection must be in place between your software and the brokerage. Trades must be executed immediately and at exact prices in order to ensure conformity. To have your software place trades for you, all you need to do is input the account number and password, and everything else is done automatically. Please note that using this feature is strictly optional.

    • Code a trading system - This software feature implements a proprietary programming language that allows you to build rules easily. For example, MetaTrader uses MQL (MetaQuotes Language). Here's an example of its code to sell if free margin is less than $5,000:

      If FreeMargin < 5000, then exit;

      Often, just reading the manual and experimenting should allow you to pick up on the basics of the language your software uses.

    • Backtest your strategy - System development without backtesting is like playing tennis without a racquet. System development software often contains a simple backtesting application that allows you to define a data source, input account information, and backtest for any amount of time with the click of a mouse. Here is an example from MetaTrader:

      After the back test is run, a report is generated that outlines the specifics of the results. This report usually includes profit, number of un/successful trades, consecutive days down, number of trades, and many other things that can be helpful when trying to determine how to troubleshoot or improve the system. Finally, the software usually creates a graph showing the growth of the investment throughout the tested time period.

2. Design - The design is the concept behind your system, the way in which the parameters are used to generate a profit or loss. You implement these rules and parameters by programming them. Sometimes, this programming can be done automatically via a graphical user interface. This allows you to create rules without learning a programming language. Here is an example of a moving average cross-over system:

If SMA(20) CrossOver EMA(13) then enter;
If SMA(20) CrossUnder EMA(13) then exit;

Rules like these that are put into code allow the software to automatically generate entry and exits at the points when the rules are applicable. Here is what the design interface looks like on MetaTrader:

The system is created by simply typing the rules in the window and saving them. References for the different functions available (for example, oscillators and such) can be found by clicking on the book icon. Most software will have a similar reference available either within the program itself or on its website. After creating the desired rules and coding the system, you simply save the file. Then you can put it into use by selecting it on the main screen.

3. Decision Making - There are many decisions to be made at this point:
  • What market do I want to trade in?
  • What time period should I use?
  • What price series should I use?
  • What subset of equities should I use for testing?

Keep in mind that trading systems should consistently make a profit in many markets. By customizing the time period and price series too much, you may taint the results and produce uncharacteristic results.

4. Practice - Backtesting and paper trading are essential to the successful development of a trading system:
  • Run several backtests on different time periods and make sure that the results are consistent and satisfactory.

  • Paper trade the system (use imaginary money, but record the trades and results), and again, look for consistent profitability.

  • Carefully check for errors in the program, or unintended trades. These can be a result of faulty programming or failure to foresee certain circumstances that have undesired repercussions.

5. Repeat - Repetition is necessary. Keep working on the system until you can consistently make a profit in most markets and conditions. There are always unforeseen events that occur as soon as a system goes live. Here are some factors that often cause skewed results:
  • Transaction costs - Make sure that you are using the real commission, and some extra to account for inaccurate fills (difference between bid and ask prices). In other words, avoid slippage! (To review what this is and how it occurs, see the preceding section of this tutorial.)

  • Watchfulness - Don't ignore losing trades; keep an eye on all trades.

  • Optimization - Don't over-optimize the system. In other words, don't tailor the system to a very specific market environment; try to be profitable in as broad of an environment as possible.

  • Risk - Never ignore or forget about risk. It is very important to have ways to limit losses (otherwise known as stop-losses), and ways to lock-in profits (take profits).

6. Trade
- Try it out, but expect unintended results. Be sure to use non-automated trading until you are confident in the system's performance and consistency. It takes a long time to develop a successful trading system, and before you perfect it, you may have to endure some live trading losses to detect glitches: back testing cannot perfectly represent live market conditions, and paper trading can be inaccurate. If your system loses money, go back to the drawing board and see where it went wrong (see step 5).

These six steps give you an overview of the entire process of building a trading system. In the next section, we will build upon this knowledge and take a more in-depth look at troubleshooting and modification.
Trading Systems: Troubleshooting And Optimization

  1. Trading Systems: Introduction
  2. Trading Systems: What Is A Trading System?
  3. Trading Systems: Designing Your System - Part 1
  4. Trading Systems: Designing Your System - Part 2
  5. Trading Systems: Constructing A System
  6. Trading Systems: Troubleshooting And Optimization
  7. Trading Systems: Conclusion
  1. Financial System

    A financial system can be defined at the global, regional or ...
  2. Forex Signal System

    A set of analyses that a forex trader uses to determine whether ...
  3. Intermarket Trading System - ITS

    An electronic computer system that joins the trading floors of ...
  4. Purchasing System

    A method used by businesses to buy products and/or services. ...
  5. Electronic Meeting System - EMS

    A computer-based system that stimulates problem-solving and decision-making ...
  6. Systemic Risk

    Investopedia explains: A systemic risk is the possibility that ...
  1. What is the difference between a capitalist system and a free market system?

    Learn about capitalist and free market systems, how these economic systems function and the main difference between capitalism ... Read Answer >>
  2. How do I pick the best method for forex system trading?

    Discover how to identify the best type of forex system trading style for you based on your available time, your trading preferences ... Read Answer >>
  3. How do I implement a Forex Signal System into a forex trading strategy?

    Learn how traders use different types of forex signal systems such as trend-based or range-based to create or supplement ... Read Answer >>
  4. What should I look for when choosing a forex trading platform?

    A trading platform is a piece of software that acts as a conduit for information between a trader and a broker. A trading ... Read Answer >>
  5. When and why are technical indicators useful?

    Discover what technical indicators are, when they are useful and how their specific design limits their meaningfulness to ... Read Answer >>
  6. What is the difference between barter and currency systems?

    Learn the difference between barter and currency systems in the trade of goods and services. Why is currency preferred over ... Read Answer >>
Hot Definitions
  1. Over-The-Counter - OTC

    Over-The-Counter (or OTC) is a security traded in some context other than on a formal exchange such as the NYSE, TSX, AMEX, ...
  2. Quarter - Q1, Q2, Q3, Q4

    A three-month period on a financial calendar that acts as a basis for the reporting of earnings and the paying of dividends.
  3. Weighted Average Cost Of Capital - WACC

    Weighted average cost of capital (WACC) is a calculation of a firm's cost of capital in which each category of capital is ...
  4. Basis Point (BPS)

    A unit that is equal to 1/100th of 1%, and is used to denote the change in a financial instrument. The basis point is commonly ...
  5. Sharing Economy

    An economic model in which individuals are able to borrow or rent assets owned by someone else.
  6. Unlevered Beta

    A type of metric that compares the risk of an unlevered company to the risk of the market. The unlevered beta is the beta ...
Trading Center