Creating A New System
Go to the "Enhanced System Tester" module.
Open the "New System" option. Fields of the System Editor include fields in which to enter the name of the system, notes and system rules. Four rules describe long/short position opening/closing criteria.
Three options are available in the General tab: Order Bias - sometimes the system generates two signals - a short one and a long one - at the same time. You can use this option to select which position the system should choose in such a situation. Portfolio Bias - you can use this option to tell the system to close all reverse, existing positions opposite to a new reverse signal the moment that such a signal appears. E.g. if we want the system to close all short positions once a new long position opening signal appears, we choode the Single option. However, if we want our portfolio to include both long and short positions, we choose the Multiple options. Position Limit - this option closes all positions before any new ones are opened. We can choose how many positions should remain open or - by turning this option off - allow up to 65,536 concurrent positions to be opened. ![]() Let us now build a system:
This formula, similarly to other rule formulas, may be expressed in a descriptive form. In this case "Open a long position if the closing price intersects from below the average of the last 25 closing prices" (similarly to the "Indicator Builder" module, you can use abbreviations - replacing "close" with "c" or "simple" with "s"). Transaction rules are very similar to indicator rules. Enter the following rules for the three other criteria. Remember to click the relevant fields first (Sell Order, Sell Short Order, i Buy To Cover Order). Sell Order : cross(mov(close,25,simple),close) Sell Short Order : cross(mov(close,25,simple),close) Buy To Cover Order : cross(close,mov(close,25,simple)) After the entering such information correctly, click on OK. If there is a syntax error in the rule, a message will be displayed to describe the error and after clicking OK, Metastock will position the cursor on the error. After correcting the formula, click on OK once again. All four buy/sell tabs have the same options: Order Type - if we want the system to include stops, limits and stop limits in the test, we can select the relevant options here.
Entry Size - in this field you can define how many units the system should buy/sell while opening/closing a position. This may be expressed by the Number of Units, by the Transaction Cost, or by the Percent of Available Equity. Expiration - the system enables th euser to close a position at the ned of the day or leave it open until a closing signal appears (as defined by the user). Strategic Delay - the system may behave just like the investor, i.e. in actuality, we have delayed access to information (by 15 minutes). To make our system more real, we can further delay transactions on future markets by any number of minutes or days, e.g. if we trade stocks and in the evenings download information updates into Metastock. Back |

