Money Management


Money Management
Any method for sensible capital and risk management is assembled under the concept Money Management. You can use Money Management for the following:
  • Setting the initial capital of a trading system
  • Setting the trading costs
  • Controlling the fundamental trading system functions
  • Controlling the alerts generated by the trading system
  • Setting basic risk parameters
Tradesignal offers Money Management functions for Charts, Scanners, Portfolios and Watchlists. You can also read them out with Equilla code and use them in your own trading systems. This way, you always have access to information like initial capital, trading costs etc. Other functionalities that are not part of the standard settings can be set up with strategies that are partly included in the delivery.

Configuring the Money Management

At the top of the properties window, select the Money Management entry to open the settings.

General

Start Date - Here you can set a date at which the trade engine should start trading. If not set, it will start trading at the first available data point.

End Date - Here you can set a date at which the trade engine should stop trading. If not set, it will continue trading indefinitely.

Initial Capital - Here you can set the initial capital for the current trading system. This is an extremely important value for calculating performance, profits, losses, etc. A system that is profitable for $100.000 might well be a losing system at $10.000.

Intrabar Tick Simulation % - Enter the percentage of the price span (high-low) that is used for the generation of an artificial tick in case of a stop or limit order being executed. This way, the behavior of the real price is simulated even though only the high, low, open and close values are available. The default value is "10%".

The Generate Orders property specifies when orders can be generated by the running strategies.
  • Intrabar - Orders can be generated with every intra-bar update (for every tick).
  • On Bar Close - Orders can only be generated when the bar closes. This mode is especially useful when a signal might be invalidated before the bar closes, which typically happens when the signals are generated based on compressed chart types like Point and Figure, Renko, Three Line Break and Kagi (these chart types can all remove bars resulting in trades being executed at prices that may not be reflected in a bar when it is closed).
The Realtime Price Source property controls which prices are used to fill orders in real time. Tradesignal supports two modes: bid/ask and last.
  • Bid/Ask - Tradesignal uses the best bid / best ask data provided by either the broker (if an order routing module has been connected) or the data provider. If neither the broker nor the data provider is delivering bid/ask prices, Tradesignal uses the last price instead (for example in the case of indices). Best bid and best ask prices are generated when a market participant wants to buy or sell a number of shares/contracts while a last price represents an actual trade that has been made. Therefore this option has the benefit of more accurate fills for your orders. The caveat is however that the results collected in real time will not match the results of back-testing which will always only use the last price.
  • Last - Tradesignal uses the last price delivered by the data provider. This is the same price as the one used to back-test the strategy. A last tick represents a trade that has been made in the market. When using this mode, Tradesignal can only fill and order after a trade has been made, even if there was a matching offer/request in the market prior to the trade. This mode ensures that real time results are closer to back-test results.
Single Entry per Trade for Statistics - Set to true, in which case trades will be based on an entry/exit pair. The property can also be set to false, in which case trades will be based solely on exits (for example and exit that exits two entries would be a single trade).

Statistics Currency

When trading multiple instruments that are quoted in different currencies, aggregated statistic values can become meaningless.For example when adding the net profit of $5 and ¥10 it is not enough to simply add the two numbers. In order to solve this both values need to be converted to the same currency before adding them.This can be either of the two given currencies or a third one. In the example both values could be converted to $, ¥ or something else like €.

Currency - The currency global statistic values should be calculated in. The available currencies are depended on your selected data provider.

Calculation Mode - Selects the method that is used to calculate the currency conversion factors for the current bar.
  • Close of Previous Bar - Use the currency values at the close of the previous bar.
  • Arithmetic Mean - Calculates the arithmetic mean of Open, High, Low and Close at the current bar.
  • Midrange - Uses the average of the highest and lowest currency value at the current bar.
  • Arithmetic Mean without Open - The average of High, Low and Close currency values at the current bar.
  • Close Weighted Mean - Calculate the arithmetic mean of High, Low and 2x Close at the current bar.
  • Open Weighted Mean - Calculate the arithmetic mean of 2x Open, High and Low at the current bar.
Apply To Risk - When this option is enabled currency conversion options will also be applied to automatic stop calculations.All numeric values in the Slippage and Commission and the Risk sections are assumed to be given in the global statistics currency.

Slippage and Commission

For realistic results in the backtest and the performance evaluation of a trading system, it is important to include the trading costs in the calculation.

Split over each trade in an Exit Order - If true, and if an order exits multiple entries, commission and slippage will be distributed evenly across each trade. If set to false, commission and slippage will be applied in full for each trade exited by an order.

Two parameters are available:

Slippage

The slippage is the possible difference between the price at the trading signal and the real price at order execution. Usually, some time passes between the order signal and the actual order execution, in which the price might move against the trader. You can enter the slippage per trade or share.

Slippage/Trade - Assumed Slippage per Order (independent of the number of shares), either as absolute number or as percent value (for this, enter a % character after the number).

Slippage/Share - Assumed Slippage per Shares (independent of the number of trades), either as absolute number or as percent value (for this, enter a % character after the number).

Commission

The commission includes all costs of the stock exchange and broker. You can enter the commission per trade or share. In addition, you can enter a commission flat rate, if your broker offers such trading conditions.

Commission/Trade - Commission per order (independent of the number of shares), either as absolute number or as percent value (for this, enter a % character after the number).

Commission/Share - Commission per shares (independent of the number of trades), either as absolute number or as percent value (for this, enter a % character after the number).

Min. Commission - Minimum commission costs per order (if set by your broker).

Max. Commission - Maximum commission costs per order (if set by your broker).

Position Sizing

Default Quantity - Enter the minimum number of shares that should be traded per order.

Max Shares - Enter the maximum number of shares for this position (maximum position size). Orders that would lead to a higher position size will not get placed.

Pyramiding - Some trading systems work with position legs, meaning that after a first trading signal, newer signals will lead to further trading activities depending on the market movement. For example, the position size may be increased or decreased for a high volatility. As default, this option is inactive. If you choose pyramiding, two settings are available:
  • Yes, Different - Further shares will be purchased in case of trading signals different to the one that caused the first action.
  • Yes, All - Further shares will be purchased in case of trading signals of any kind.
If you select pyramiding, you can enter a maximum number of open entries (Max. Open Entries).

Risk

Here you can find static risk settings like Stop Loss and Trailing Stop and also more dynamic parameters. In the following, the parameters in the Money Management properties and their corresponding Equilla functions are given.

Stop Mode - Stop Mode has to be chosen in combination with the Stop Loss and Trailing Stop.
  • In Contract mode (corresponding to Share), the settings of Stop Loss and Trailing Stop are interpreted in relation to each share. For example, a Stop Loss of "100" is taken into account for each contract, independent of the position size. If the price drops by 100 from the starting value, the Stop Loss is set off.
  • In Position mode, the settings of Stop Loss and Trailing Stop are interpreted in relation to the complete position. For example, a Stop Loss of "100" will cause a position to be closed when the total loss is 100. This might actually be four points per share for Futures or one dollar for one hundred stocks.
SetStopMode(Mode)
SetStopShare // Alias to SetStopContract
SetStopContract
SetStopPosition


Profit Target - This value in currency or points (depending on the security) gives the profit the position has to reach to be closed instantly. Profit targets may help you to stabilize your trading results over a longer time span.

SetStopProfitTarget(Value)


Stop Loss - This value in currency or points (depending on the security) gives the maximum acceptable loss after the entry, at which point the position is instantly closed. A Stop Loss can protect you from overly high losses and secure your financial ability to act in the future.

SetStopLoss(Value)


Break Even - This value in currency or points (depending on the security) gives the profit of the position that has to be reached before a position is closed once the market moves against it. It is based on the idea that positions that were once in the profit area should not move into a loss. Instead, they are closed, for example to cover the trading expenses.
SetStopBreakEven(Value)


Profit Trailing - This value in currency or points (depending on the security) gives the maximum drawback of a position profit before the position is closed. This is a simple method with which to avoid losing achieved profit.

SetStopProfitTrailing(Value)


% Trailing (Floor) - This is a more flexible version of the Profit Trailing stop. With the Floor parameter you enter a profit target at which the trailing stop will get activated. With the % Trailing (%) parameter you set the maximum loss (in percent) of the position profit before the position is closed.

SetStopPercentTrailing(ProfitTarget, PercentLoss)


Include Commission/Slippage - Here you can choose whether the values for commission and slippage you entered in the above areas of the Money Management should be taken into account for the risk calculation.

Alerts

Here you can select four possible situations (Order added, changed, cancelled, filled) in which an alert shall be issued. You can find more information in the Alerts chapter.

Strategies for Money Management

In the scope of delivery for Tradesignal, several strategies can be found that you can use for Money Management.

Stops and Exits

Fast Profit Exit - Exits a position if it yields profit the day after entry.

Peak Exit - Exits a position if it made a profit and the trade changes direction against you. It is based on a complex calculation that includes an Average True Range indicator.

Percent Trailing Stop - Corresponds to the setting in the Money Management area.

Profit Target Exit - Corresponds to the setting in the Money Management area.

Profit Trailing Stop - Corresponds to the simple Trailing Stop in the Money Management area.

Stop Loss - Corresponds to the Stop Loss setting in the Money Management area.

Timed Exit - Exits a position at a given time of day, e.g. "1900".

Timed Exit (Bars) - Exits the position at a given number of trading periods.

Position Sizing

Position Sizing - Fixed Fractional - Sets the position size depending on given fractions of capital.

Position Sizing - Fixed Fractional Percent - Uses a combination of the method above and other methods to define the fraction size.

Position Sizing - Fixed Percent - Uses a defined percentage of the capital for defining the position size.

Position Sizing - Fixed Risk - Measures the volatility in the market and scales the position size accordingly. Especially useful in combination with a Volatility Stop.

Position Sizing - Market's Money - Sets the position size depending on the performance of the trading system. If the total performance is in the profitable area, more positions are entered. If the performance is negative, the position size is reduced.

Position Sizing - Percent Volatility - This is a variant of the Fixed Risk method, in which position sizing is scaled depending on the volatility of the market.

Money Management and Equilla

Several parameters that have to do with Money Management can be read out or set with Equilla commands. This way, you are in complete control of share numbers, open prices, commissions and slippage.

Read slippage:

//Gives the slippage according to the Money Management parameters
Value1 = Slippage( Price, Quantity );


Read commission:

//Gives the commission according to the Money Management parameters
Value1 = Commission( Price, Quantity);


Read initial capital:

//Gives the initial capital according to the Money Management parameters
Value1 = InitalCapital;


In addition, you can read out many more parameters of open and close positions. See the chapter Equilla Functions for more information.

Example: Parameters for a simple trading system

The following parameters could be used for a trading system with Money Management based on Candlestick Engulfing Patterns:

Chart:
  • .NDX.X
  • History Length in the chart properties to "2000"
Strategies:
  • Candle Bearish Engulfing - Entry
  • Candle Bullish Engulfing - Entry
Money Management:
  • Slippage/Trade to 2 points
  • Commission/Trade to 2 points
  • Default Quantity to 10 contracts
  • Stop Mode to "Contract"
  • Profit Target activate with a value of "225" (click on the number next to the checkbox and edit it)
  • Stop Loss activate with a value of "40" (click on the number next to the checkbox and edit it)
  • % Trailing (Floor) to 75 points
  • % Trailing (%) to 5 points
Now a first trading system is configured. You can find more strategies for Stops, Position Sizing and Statistics under Add Strategy in the toolbar.