Difference between revisions of "Configuring Strategies"

From MultiCharts
Jump to navigation Jump to search
 
(18 intermediate revisions by 4 users not shown)
Line 2: Line 2:
 
== Understanding Strategies ==  
 
== Understanding Strategies ==  
  
A strategy is a set of signals, applied to a chart. Signals systematically specify market entry or exit points according to a set of trading rules implemented in the signals' algorithms, and can be viewed as the basic building blocks of strategies.  
+
A strategy is a set of signals, applied to a symbol. Signals systematically specify market entry or exit points according to a set of trading rules implemented in the signals' algorithms, and can be viewed as the basic building blocks of strategies.  
  
 
Over 100 pre-built, customizable signals, covering the most popular trading concepts, are already included with the platform, and additional signals can be imported from a variety of sources.  
 
Over 100 pre-built, customizable signals, covering the most popular trading concepts, are already included with the platform, and additional signals can be imported from a variety of sources.  
Line 8: Line 8:
 
Signals can be fully customized, or entirely new signals created, using PowerLanguage® scripting in '''PowerLanguage Editor'''.   
 
Signals can be fully customized, or entirely new signals created, using PowerLanguage® scripting in '''PowerLanguage Editor'''.   
  
A portfolio can contain several strategies.  
+
A portfolio can contain numerous strategies.  
  
Each strategy can have its own list of symbols and signals.  It is to possible apply different strategies to different sets of symbols.
+
Each strategy can have its own list of symbols and signals.  It is possible to apply different strategies to different sets of symbols.
  
 
Basic adjustments to a signal's logic can be made by simply changing the '''Input Values'''. Signals can have one or more inputs, or none at all. Multiple instances of the same signal can be used in the same strategy, and each instance can have different input settings.
 
Basic adjustments to a signal's logic can be made by simply changing the '''Input Values'''. Signals can have one or more inputs, or none at all. Multiple instances of the same signal can be used in the same strategy, and each instance can have different input settings.
Line 16: Line 16:
 
Strategies can be constructed by simply combining a number of signals.  
 
Strategies can be constructed by simply combining a number of signals.  
  
Signal settings are specific to each particular signal, while [[Strategy_Properties|Strategy Properties]] regulate the actions of a group of signals as a whole.
+
[[Signal_Settings|Signal settings]] are specific to each particular signal, while [[Strategy_Properties|Strategy Properties]] regulate the actions of a group of signals as a whole.
  
 
<br>
 
<br>
Line 24: Line 24:
 
To add a strategy to a portfolio:
 
To add a strategy to a portfolio:
  
 +
# Open '''Portfolio Trader''' window.
 +
#* see '''[[Portfolio Trader#Opening Portfolio Trader|how]]'''.
 
# Under the main menu select '''Portfolio'''.
 
# Under the main menu select '''Portfolio'''.
 
# Select '''Add Strategy'''.
 
# Select '''Add Strategy'''.
Line 30: Line 32:
 
== Cloning Strategies ==
 
== Cloning Strategies ==
  
To clone a strategy right-click on the strategy and click '''Clone Strategy'''.
+
To clone a strategy right-click on the strategy in the '''Portfolio Tree''' window and click '''Clone Strategy'''.
  
 
== Adding Signals ==  
 
== Adding Signals ==  
Line 46: Line 48:
 
You can also drag and drop signals from one strategy to another.
 
You can also drag and drop signals from one strategy to another.
  
<div style="background-color: #E3FBE5;">Note: Only the compiled (those with the '''Ready Status''' or '''Yes''') signals can be inserted. To learn more see [[Editing_Study_Scripts#Compiling Scripts|Compiling Studies]]</div>
+
<div style="background-color: #E3FBE5;">Note: Only the compiled (those with the Ready Status = Yes) signals can be inserted. To learn more see [[Editing_Study_Scripts#Compiling Scripts|Compiling Studies]]</div>
  
 
== Removing Signals ==  
 
== Removing Signals ==  
Line 59: Line 61:
 
<br>
 
<br>
  
== Copy and Paste Signals ==
+
== Copying Signals ==
  
To copy / paste a signal right-click on the signal and click '''Copy''' / '''Paste'''.
+
To copy/paste a signal right-click on the signal and click '''Copy''' / '''Paste'''.
  
  
Line 85: Line 87:
 
<br>
 
<br>
  
== Turning Signals On and Of ==  
+
== Turning Signals On and Off ==  
  
 
Signals can be turned on or off. The script of a signal that is turned off will not be executed and will not generate orders.
 
Signals can be turned on or off. The script of a signal that is turned off will not be executed and will not generate orders.
Line 97: Line 99:
 
# Select the '''Status''' button to toggle the signal on or off.
 
# Select the '''Status''' button to toggle the signal on or off.
 
# Click the '''OK''' button.
 
# Click the '''OK''' button.
 +
 +
<br><div style="background-color: #E3FBE5;">Since '''MultiCharts 11''' it is possible to turn signals on and off in Portfolio by simply checking or unchecking the corresponding checkbox next to the signal in '''Portfolio Tree'''.</div>
  
 
<br>
 
<br>
 +
== Turning Strategies On and Off ==
 +
 +
Since '''MultiCharts 11''' it is possible to turn strategies on and off in Portfolio by simply checking or unchecking the corresponding checkbox next to the strategy in '''Portfolio Tree'''. <br>
 +
To select or de-select all strategies right-click on an empty space in Portfolio Tree and choose '''Check''' / '''Uncheck All strategies'''.
  
 
== Changing Signal Priority ==  
 
== Changing Signal Priority ==  
Line 104: Line 112:
 
If all entries' execution generated for a portfolio causes the capital limits to be exceeded, then the entries with the highest priority will receive preference, while the entries with the lowest priority will not be executed.
 
If all entries' execution generated for a portfolio causes the capital limits to be exceeded, then the entries with the highest priority will receive preference, while the entries with the lowest priority will not be executed.
  
The priority of a symbol is the order in which it is listed in the Symbol List of the Portfolio Backtester.  
+
The priority of a symbol is the order in which it is listed in the Symbol List of the Portfolio Trader.  
  
 
Signal priority can also be specified in PowerLanguage using the <code><b>[[PortfolioEntriesPriority|PortfolioEntriesPriority]]</b></code> keyword.
 
Signal priority can also be specified in PowerLanguage using the <code><b>[[PortfolioEntriesPriority|PortfolioEntriesPriority]]</b></code> keyword.
Line 135: Line 143:
 
To change a signal's inputs:
 
To change a signal's inputs:
  
# Open '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
+
# Open the '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
 
# Right-click on the signal.
 
# Right-click on the signal.
 
# Select '''Format Signal'''.  The Format Signals window will appear.  The table will show available inputs.
 
# Select '''Format Signal'''.  The Format Signals window will appear.  The table will show available inputs.
 
# In the '''Value''' column, click on the value of the input to be changed and enter the desired value.
 
# In the '''Value''' column, click on the value of the input to be changed and enter the desired value.
 +
 +
<br><div style="background-color: #E3FBE5;">Since '''MultiCharts 11''' it is possible to view the signals of a strategy and their inputs by hovering the mouse over the strategy’s name in the Symbols Table (see [[Operating_Portfolios#Understanding_the_Symbols_Table]]).</div>
  
 
<br>
 
<br>
Line 146: Line 156:
 
Strategy properties are separate from the individual signals' settings, affect all of the signals in a strategy, and regulate the actions of a group of signals as a whole.
 
Strategy properties are separate from the individual signals' settings, affect all of the signals in a strategy, and regulate the actions of a group of signals as a whole.
  
Strategy properties include '''Costs/Capitalization''', '''Maximum bars back''', '''Position limits''', and '''Trade size''' sections.
+
Strategy properties include '''Costs/Capitalization''', '''Maximum Bars Back''', '''Position Limits''', and '''Trade Size''' sections.
  
 
<br>
 
<br>
 +
 
== Costs/Capitalization ==  
 
== Costs/Capitalization ==  
  
 
To change costs or/and capitalization assumptions:
 
To change costs or/and capitalization assumptions:
  
# Open '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
+
# Open the '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
 
# Right-click on the strategy.
 
# Right-click on the strategy.
 
# Select '''Show Properties'''. The '''Format Settings''' window will appear.
 
# Select '''Show Properties'''. The '''Format Settings''' window will appear.
Line 166: Line 177:
  
 
<br>
 
<br>
 +
 
== Maximum Number of Bars Study Will Reference ==  
 
== Maximum Number of Bars Study Will Reference ==  
  
 
All signals based on past data use a certain number of bars for their calculations.  
 
All signals based on past data use a certain number of bars for their calculations.  
  
The '''maximum number of bars study will reference''' must be greater than or equal to the number of bars that the signal uses.   
+
The '''maximum number of bars a study will reference''' must be greater than or equal to the number of bars that the signal uses.   
  
 
For example, if the signal uses the past 10 bars to make its calculations, the '''maximum number of bars study will reference''' must be greater than or equal to 10.
 
For example, if the signal uses the past 10 bars to make its calculations, the '''maximum number of bars study will reference''' must be greater than or equal to 10.
Line 176: Line 188:
 
To change the '''maximum number of bars study will reference''':
 
To change the '''maximum number of bars study will reference''':
  
# Open '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
+
# Open the '''Portfolio Tree''' window<br><span>{{FormatPWindow}}</span>
 
# Right-click on the strategy.
 
# Right-click on the strategy.
 
# Select '''Show Properties'''.  The '''Format Settings''' window will appear.
 
# Select '''Show Properties'''.  The '''Format Settings''' window will appear.
Line 183: Line 195:
  
 
<br>
 
<br>
 +
 
== Position Limits ==  
 
== Position Limits ==  
  
Line 222: Line 235:
 
<br>
 
<br>
  
[[Category:Portfolio Backtester]]
+
[[Category:Portfolio Trading]]

Latest revision as of 17:35, 19 August 2019


Understanding Strategies

A strategy is a set of signals, applied to a symbol. Signals systematically specify market entry or exit points according to a set of trading rules implemented in the signals' algorithms, and can be viewed as the basic building blocks of strategies.

Over 100 pre-built, customizable signals, covering the most popular trading concepts, are already included with the platform, and additional signals can be imported from a variety of sources.

Signals can be fully customized, or entirely new signals created, using PowerLanguage® scripting in PowerLanguage Editor.

A portfolio can contain numerous strategies.

Each strategy can have its own list of symbols and signals. It is possible to apply different strategies to different sets of symbols.

Basic adjustments to a signal's logic can be made by simply changing the Input Values. Signals can have one or more inputs, or none at all. Multiple instances of the same signal can be used in the same strategy, and each instance can have different input settings.

Strategies can be constructed by simply combining a number of signals.

Signal settings are specific to each particular signal, while Strategy Properties regulate the actions of a group of signals as a whole.


Adding Strategies

To add a strategy to a portfolio:

  1. Open Portfolio Trader window.
  2. Under the main menu select Portfolio.
  3. Select Add Strategy.


Cloning Strategies

To clone a strategy right-click on the strategy in the Portfolio Tree window and click Clone Strategy.

Adding Signals

The number of signals/strategies that can be added to a portfolio is limited only by your computer's hardware configuration.

To add a signal to a portfolio:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Expand the Strategy for which the signal will be added.
  3. Right-click on the Signals node and select Add Signals.
  4. Select a signal from the Add Signals window.
  5. Select OK.

You can also drag and drop signals from one strategy to another.

Note: Only the compiled (those with the Ready Status = Yes) signals can be inserted. To learn more see Compiling Studies

Removing Signals

To remove a signal:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Expand the Strategy for which the signal will be removed.
  3. Expand the Signals node.
  4. Right-click on the signal to be removed and select Remove Signal.


Copying Signals

To copy/paste a signal right-click on the signal and click Copy / Paste.


Note: To select multiple signals at once select a signal, hold the Shift button and move up or down the list of signals using the Up or Down Arrow buttons.

Signals List

To see which signals are applied to a portfolio:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Expand the Strategy that contains the signals.
  3. Expand the Signals node.


Note: The signals' execution priority is assigned according to the order in which they appear in the Signals List, with the signals at the top of the list having a higher priority.


To view the available input parameters of a particular signal

  1. Right-click on the signal.
  2. Select Format Signal. The Format Signals window will appear. The table will show available inputs.
  3. In the Value column, click on the value of the input to be changed and enter the desired value.
    Name – name of the signal
    Inputs – input parameters of the signal; to learn more see Default Studies Inputs and Setting Studies Inputs


Turning Signals On and Off

Signals can be turned on or off. The script of a signal that is turned off will not be executed and will not generate orders.

To turn a signal on or off:

  1. Open Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the strategy in which the signal resides.
  3. Select Show Signals. The Format Settings window will appear.
  4. Select the Signals tab.
  5. Select the Status button to toggle the signal on or off.
  6. Click the OK button.


Since MultiCharts 11 it is possible to turn signals on and off in Portfolio by simply checking or unchecking the corresponding checkbox next to the signal in Portfolio Tree.


Turning Strategies On and Off

Since MultiCharts 11 it is possible to turn strategies on and off in Portfolio by simply checking or unchecking the corresponding checkbox next to the strategy in Portfolio Tree.
To select or de-select all strategies right-click on an empty space in Portfolio Tree and choose Check / Uncheck All strategies.

Changing Signal Priority

If all entries' execution generated for a portfolio causes the capital limits to be exceeded, then the entries with the highest priority will receive preference, while the entries with the lowest priority will not be executed.

The priority of a symbol is the order in which it is listed in the Symbol List of the Portfolio Trader.

Signal priority can also be specified in PowerLanguage using the PortfolioEntriesPriority keyword.


Moving a Signal to a Different Strategy

To move a signal to a different strategy:

Drag the signal from the strategy in which it resides and drop it into the Signals node of the new strategy.


Setting Signal Input Values

An Input is a constant used in the signal's calculations.

Signals can have one or more inputs, or none at all. Each input is assigned a name.

There are three types of inputs: Numeric, True/False, and String.

Signals can be modified by changing the input Values.

One of the main advantages of using the inputs is that basic adjustments to the study's logic can be made by simply changing the input values, without the need to edit the studies' actual code.

Multiple instances of the same signal can be used in the same strategy, and can have different input settings.

Inputs are also used for Trading Strategy Optimization.

To change a signal's inputs:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the signal.
  3. Select Format Signal. The Format Signals window will appear. The table will show available inputs.
  4. In the Value column, click on the value of the input to be changed and enter the desired value.


Since MultiCharts 11 it is possible to view the signals of a strategy and their inputs by hovering the mouse over the strategy’s name in the Symbols Table (see Operating_Portfolios#Understanding_the_Symbols_Table).


Strategy Properties

Strategy properties are separate from the individual signals' settings, affect all of the signals in a strategy, and regulate the actions of a group of signals as a whole.

Strategy properties include Costs/Capitalization, Maximum Bars Back, Position Limits, and Trade Size sections.


Costs/Capitalization

To change costs or/and capitalization assumptions:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the strategy.
  3. Select Show Properties. The Format Settings window will appear.
  4. Select the Properties tab.
  5. In the Costs/Capitalization section, enter the commission dollar amount in the Commission textbox, and:
    • Select per Trade to specify that the dollar amount entered represents commission per trade, or
    • Select per Share/Contract to specify that the dollar amount entered represents commission per share/contract
  6. In the Costs/Capitalization section, enter the slippage dollar amount in the Slippage textbox, and:
    • Select per Trade to specify that the dollar amount entered represents slippage per trade, or
    • Select per Share/Contract to specify that the dollar amount entered represents slippage per share/contract
  7. In the Interest Rate textbox, enter the interest rate, to be used in performance ratio calculations.


Maximum Number of Bars Study Will Reference

All signals based on past data use a certain number of bars for their calculations.

The maximum number of bars a study will reference must be greater than or equal to the number of bars that the signal uses.

For example, if the signal uses the past 10 bars to make its calculations, the maximum number of bars study will reference must be greater than or equal to 10.

To change the maximum number of bars study will reference:

  1. Open the Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the strategy.
  3. Select Show Properties. The Format Settings window will appear.
  4. Select the Properties tab.
  5. In the Costs/Capitalization section, enter a number in the Maximum number of bars study will reference textbox.


Position Limits

Position Limits settings control the maximum number entry orders in the same direction and the maximum number of shares/contracts per position.

To enter position limits:

  1. Open Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the strategy.
  3. Select Show Properties. The Format Settings window will appear.
  4. Select the Properties tab.
  5. In the Position Limits section, select the check box to enable order limits in the same direction.
  6. Enter the number of entry orders permitted in the same direction into the textbox.
    • Select when the order is generated by a different entry order radio button to apply the entry order limit only when the entry orders originated from different signals, or
    • Select regardless of the entry that generated the order radio button to apply the entry order limit regardless of whether the entry orders originated from the same or different signals.
  7. In the Maximum shares/contracts per position textbox, enter the maximum shares/contracts permitted.


Trade Size

Trade size settings set the size of each trade, either by the number shares/contracts or by currency value.

Trade size settings select the number shares/contracts or the currency value per each trade.

Note: These settings are ignored if trade size is specified by the signal.

To enter the trade size:

  1. Open Portfolio Tree window

     To open the Portfolio Tree window:

        1. Go to Portfolio Trader application.
        2. Under the main menu click View and then select Portfolio Tree.

  2. Right-click on the strategy.
  3. Select Show Properties. The Format Settings window will appear.
  4. Select the Propertiestab.
  5. In the Trade Size section,
    • Select the Fixed Shares/Contracts radio button to enter the trade size in terms of shares/contracts, or
    • Select the Dollars per Trade radio button to enter the trade size in terms of dollars, or
      • Enter a whole number to specify how fractional shares/contracts will be rounded
      • In the Minimum number shares/contracts box, enter the minimum number of shares/contracts.
    • Select the Percent of Equity radio button to enter the trade size in terms of percent of equity.