AUTOTRADING

Questions about MultiCharts and user contributed studies.
ADG88
Posts: 27
Joined: 11 Oct 2013
Has thanked: 9 times

AUTOTRADING

Postby ADG88 » 23 Mar 2015

Hallo,

While the trading system was autotrading MC tells that the strategy is being calculated.

If it happens I have to turn off autotrading and turn on again.

This is my doubt: If a signal occurs when the strategy is turned in automated mode but is being calculated the trade will be filled or not filled?

Thanks a lot.

Regards,
Alessandro
Attachments
ERROR.png
(100.66 KiB) Downloaded 414 times

tony
Posts: 420
Joined: 14 Jun 2013
Has thanked: 30 times
Been thanked: 81 times
Contact:

Re: AUTOTRADING

Postby tony » 23 Mar 2015

I don't understand your question but let me try and share my own experience to hopefully answer. If you have a work station opened with a signal (script) inserted, then your script (signal) is calculated based on how it was written.

Now if auto-trading is ON, then orders are generated and transmitted via your broker profile, etc and submitted. If auto-trading is not on, then orders are generated but not transmitted via your broker profile.

If you turn auto-trading off and then back on, but before you turned it back on an order was generated, I do not believe the order would be transmitted once you turned auto-trading on.

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: AUTOTRADING

Postby Henry MultiСharts » 26 Mar 2015

Hello Alessandro,

No orders are generated/sent in Calculating state. The strategy will start trading once it is calculated.

Most likely you have specified MaxBarsBack value that is higher than the amount of bars on the chart:
• MaxBarsBack is the amount of bars that would be used for initial script calculation, to get the initial value of functions, variables. This amount of bars would be skipped, so you will see a first signal on maxbarsback+1 bar (for ex, may vary depending on the strategy).
• For signals - the minimum MaxBarsBack is the largest MaxBarsBack required by all signals applied to the chart. For ex. you have data1=1 min, data2=1 day. If an Average in your code references data2 with Length=10, then the required MaxBarsBack value is 10. 10 days of data will be skipped on both series. If your code does not reference additional data series then bars of data1 will be skipped only.
• For indicators - the minimum MaxBarsBack is the largest look back (Length) required for calculation in this indicator.
• Chart data range should be higher than MaxBarsBack value.
• If your MaxBarsBack value is not enough the study would not be calculated and will show an error message.
• If your MaxBarsBack is too high (more than the amount of bars on your chart) then the study will be waiting for the required amount of bars. On the chart you can see "Strategy calculating" message in such case or "Calculating" for an indicator.


Return to “MultiCharts”