Table of Contents

Strategy Builder Manual

Important note for contacting technical support

If you are contacting technical support concerning a specific issue with your strategy’s execution, please attach the following in your email:

  1. A copy of your saved strategy file
  2. A full screenshot of your MotiveWave chart with the relevant studies and strategy applied

Without your strategy file, it will likely be impossible for us to gauge the source of the issue as we cannot replicate it on our end. If you prefer to keep your strategy confidential, please create a minimalized version of your strategy such that the issue is still reproducible.

What is the Strategy Builder?

The Strategy Builder is a MotiveWave strategy that can be applied to your chart, activated, and run – just like a normal strategy. The difference is that the Strategy Builder is not a strategy in itself.

Instead, it provides a unique interface which allows you to click together a custom strategy of your choosing by combining study plot, account, and time conditions, as well as entries, exits, targets, and stops.

How does it work?

The anatomy of a Strategy Builder strategy

Strategy Builder strategies are made up of three main components:

  1. Global Settings
  2. Trading Plans
  3. Targets and Stops

Global Settings

Global Settings

The global settings are the high-level settings which affect the strategy as a whole. They are independent of, and take priority over the settings of any one trading plan, target, or stop.


The calculate mode is particularly important. It sets both the time at which the strategy evaluates its trading plans’ conditions, as well as when the strategy will read the values of the studies its plans rely on.

When ‘Calculate’ is set to ‘On bar open’, the strategy will evaluate its trading plans’ conditions at the open of a new bar.

When ‘Calculate’ is set to ‘On bar update’ it strategy will evaluate its trading plans’ conditions at every update or tick of the current bar.

When ‘Calculate’ is set to ‘On bar close’, it will evaluate its trading plans’ conditions at the close of the current bar.

Stops and targets are always evaluated intra-bar, regardless of the selected calculate mode.

Max. entries per direction

The maximum entries per direction determines the number of independent trades can be opened in the same direction by the strategy’s trading plans at any one time.

Take for example a strategy which has two trading plans:

  1. Go long 100 shares when the Close crosses above the SMA(C, 50)
  2. Go long 100 shares when the Close crosses above the SMA(C, 100)

Now, imagine that this strategy has its ‘Max. entries per direction’ set to 1, and that the Close price is below both the SMA(C, 50) and the SMA(C, 100) on the current bar.

On the next bar, the Close crosses above the SMA(C, 50) and the strategy goes long 100 shares. The strategy has now reached its max entries per direction. No new long entries will be taken by the second plan once the Close crosses above the SMA(C, 100), or any other plan if there were any. The strategy will remain in this state until one of four things happens:

  • The long position from Plan 1 is closed out by its own exit, or by the exit from another plan
  • The long position from Plan 1 is closed out completely by its target(s) or stop(s)
  • A short entry from another plan causes the account position to reverse
  • The account position is reversed or closed completely by some other event (close on session end, a manual exit, strategy deactivation, etc.)

Debug Mode

This setting, when enabled, prints debugging statements for the Strategy Builder to MotiveWave’s output log. It should only be used when you are working together with technical support to fix an issue.

Trading Plans

An introduction to trading plans

Trading plans are the main focus of the Strategy Builder. It’s in these plans that you define the main logic of your strategy.

A trading plan consists of three parts:

  1. Conditions
  2. Actions
  3. Targets and Stops

Every time the Strategy Builder calculates your strategy, it re-evaluates the conditions of each of your trading plans. If all of a trading plan’s conditions evaluate to true, then the Strategy Builder takes the ‘Actions’ defined by that plan.

There can only be 1 open position per plan. If a plan’s conditions evaluate to true and an entry is taken to open a trade, then that plan will not execute its entry action again until that first opened trade’s entry order is filled, rejected, or cancelled, and the resulting open position (if any) is closed.

All trading plans – and strategies as a whole – are inherently stop-and-reverse. This means that, across all plans, a strategy will only ever have a total position open in one direction at a time.

When a plan creates an entry order in a direction opposite to the current account position, then the open account position in the existing direction will first be closed before the entry order in the new direction is submitted.

As an example, if Plan 1 and Plan 2 have an open long position, and Plan 3 initiates a short entry, then Plan 1 and Plan 2 will have their long positions closed or reversed as Plan 3’s short entry order is placed.


Trading plans can have study value, price, and number based conditions (in ‘Plots’), account and strategy based conditions such as ‘Unrealized PnL’ or ‘Market Position’ (in ‘Account’), and time based conditions, such as ‘Is/is not a certain day of the week’ or ‘Bar Time Starts at 12:30’ (in ‘Time’).

All of a trading plan’s enabled conditions must be met for the Strategy Builder to take that plan’s actions. We plan to include an ‘If All/If Any’ option in the future, so that you can decide whether at least one of a plan’s conditions must be met, or all of them.


Actions are the steps a strategy takes when a trading plan’s conditions are satisfied. A plan’s actions can include both an entry and an exit.

A plan’s entry action will not execute if that entry has already executed and the position it opened has not closed yet.

A plan’s exit action will always execute – so long as a position in the associated direction is open. As is the case with targets and stops, an exit’s size will always be minimized to the account’s available position size. Eg. if the account is long 50 shares and a plan’s ‘Exit 75 shares’ exit action is executed, then the exit’s size will be reduced from 75 to 50 shares.

Targets and stops

Targets and stops must be associated with a plan to have any effect.

We are looking to implement independent targets and stops which can be associated with the overall account position in the future.


Create and save a new strategy

Creating a new strategy is easy. After opening the Strategy Builder, simply:

  1. Select ‘Create a new strategy’ from the ‘I would like to’ drop-down
  2. Enter a strategy name (required)
  3. Click ‘browse’ to select a save location to which your strategy file will be saved (required)
  4. Click ‘Create’ if you have just opened the Strategy Builder, or ‘Update’ if it is already applied to the chart

That’s it – your strategy file should now be saved to your selected location, and any future clicks of the ‘Update’ or ‘Apply’ button will save your latest settings to the strategy file.

Please be aware when selecting your save location that some folders on your device may not be accessible to MotiveWave – if this is the case, a warning dialog will pop up to inform you.

Load, overwrite, and rename an existing strategy

Loading a strategy

To load an existing strategy:

  1. Select ‘Load a strategy’ from the ‘I would like to’ drop-down
  2. Click ‘Browse’ and navigate to your strategy file. Select it and click ‘Open’.
  3. Click ‘Create’ if you have just opened the Strategy Builder, or ‘Update’ if it is already applied to the chart. The settings will then be loaded
  4. Your loaded strategy will now be overwritten whenever you click ‘Update’ or ‘Apply’ if ‘Overwrite with new changes’ is enabled

If you want to rename this strategy you’ve just loaded, simply switch to ‘Create a new strategy’, and follow the steps to create a new strategy. After clicking ‘Update’ or ‘Apply’, the Strategy Builder will create a new strategy file under the new name.

Create a simple SMA Crossover strategy

Add simple targets and stops to an SMA Crossover strategy

Build a strategy around 1-2-3 Strike!

The strategy file built in this video can be downloaded here. Please make sure to apply 1-2-3 Strike! to the chart with its default settings applied before loading this file into, and applying, the Strategy Builder.

Recommended workflows

Creating a new strategy

The recommended steps for creating a new strategy

Using or modifying an existing strategy

The recommended steps for using or modifying an existing strategy file

FAQs and Troubleshooting

An important note about studies

The Strategy Builder is built around the idea that it can rely on the values generated by the studies it uses. If you are using the ‘On bar open’ or ‘On bar update’ calculate modes, ‘Bar Updates’ must be enabled in the studies your strategy relies on.

If ‘Bar Updates’ is not enabled, then when the Strategy Builder checks your studies’ values at the open or update of a bar to evaluate your Trading Plan conditions,  it will find no usable values – as nothing has been calculated by your studies yet.

If ‘Bar Updates’ is disabled, your studies are waiting until the close of the current bar to calculate their values, and unless the Strategy Builder is running in ‘On bar close’ calculate mode, it will not be able to evaluate them.

Why aren’t my study’s plots visible in the ‘Plots’ conditions window?

In order for a study’s plots to be visible in the Strategy Builder, the study must:

  1. Be applied to the same graph as the Strategy Builder (the ‘Price Graph’):
Set ‘Graph’ to ‘Price Graph’ in your study’s options tab

2. Export its plot values to the ‘Cursor Data Window’:

Your studies’ plots must visible in the ‘Cursor Data Window’ to be used in the Strategy Builder

‘Bar Updates’ are enabled, but it’s still not working

Because some third-party studies might have quirks in the way they calculate their values, there is still a lot of room in these early versions of the Strategy Builder for unforeseen issues. Most commonly, these issues caused by third-party studies are related to late calculation within the study – where the most recent value might only be available one or two bars ago instead of on the current bar.

Why aren’t my conditions executing/orders generating?

There are currently 3 known potential reasons, listed from most to least likely:

  1. Your strategy uses ‘On bar open’ or ‘On bar update’ in its Global Settings, but the studies it relies on do not have ‘Bar Updates’ enabled in their ‘Options’ tab
  2. Your strategy relies on third-party studies which have bugs
  3. An error is occurring within the Strategy Builder. If you think this is the case, please contact technical support at [email protected] We will walk you through the debugging process to get to the bottom of it.

Every time I make changes to a loaded strategy and then click ‘Create’, ‘Update’, or ‘Apply’, the changes are forgotten and the strategy reverts to the initially loaded settings

You likely have ‘Overwrite with new changes’ disabled in the ‘Welcome’ tab. Every time you are clicking ‘Create’, ‘Update’, or ‘Apply’, the Strategy Builder merely reloads the strategy file it was provided with, ignoring all of your changes.

Why aren’t the ‘On bar update’ or ‘On bar open’ calculate modes working for me

Please refer to the question above: “Why aren’t my conditions executing/orders generating?”

Can my Strategy Builder strategies be run in the Optimizer?

Unfortunately not – they need to be run in Replay mode. This is not something that MotiveWave is currently capable of.

Strategy Builder strategies rely on studies and plots that are visible on the same chart to which they are applied. They cannot be run in the Optimizer because these studies and plots are not applied or visible from within it.

We are looking into a potential future feature that can serve as a workaround for this by adding some on-chart optimization capabilities into the Strategy Builder itself. We think this would be a powerful feature to help work around the inability to run in the optimizer – but we’re going to have to give it some thorough investigation to see if it’s even possible.

Will you be adding plot conditions for stops and targets?

Yes – we intend to, and it is high on our list of priorities for future features.


How-to clips

Creating a Simple SMA Crossover Strategy

Adding targets and stops to a simple SMA Crossover strategy

Building a strategy around 1-2-3 Strike!

The strategy file built in this video can be downloaded here. Please make sure to apply 1-2-3 Strike! to the chart with its default settings applied before loading this file into, and applying, the Strategy Builder.

Working with non-overlay studies

Introductory tutorial series

Welcome, Strategy Builder Beta Testers

Installing the Strategy Builder

Beta Settings Overview

Creating Our First Strategy

You can download the DailySMA study here.

In progress – more videos coming this week:

  • Creating a scaled entry and exit strategy
  • Building a strategy for the Power Bundle 360 indicators
  • Creating a strategy using non-overlay studies

Intended features to come

  • Limit, stop, stop limit, and trailing stop orders
  • Stop limit orders at OHLC prices or plot value
  • Break-even options for stops
  • Investment-based entry size
  • Risk-based entry, exit, target, and stop order sizes
  • Plot-based, conditional entry, exit, target, and stop order sizes and prices
  • Robust error handling and on-chart information display
  • Duplicable trading plans, stops, and targets
  • On-chart optimization capabilities (Future)