Login Page - Create Account

Support Board


Date/Time: Sat, 18 May 2024 16:32:49 +0000



Post From: Simultaneous live/demo algo trading on one instance

[2024-04-09 14:01:54]
emmanuel - Posts: 37
A trading study can only take trades on the trading account that's selected for the chart. So in the simplest sense, no it's not possible to have some trades on one account and other trades on another account.

However, with some cleverness it may be possible to split trades as you suggested. You will first have to run two copies of the trading algo on separate charts; One copy per trading account. Then, you need a way for both instances of the algo to communicate with each other.

DETERMINISTIC APPROACH

This approach actually avoids the requirement that the two algo instances need to communicate with each other. Instead of communication, each instance "knows" which trades to take because the decision making process happens exactly the same way every time, without fail.

An example would be that trade A always takes place on demo, but that it if triggers trade B always takes place on live. This can work because an algo can detect if a trade tiggers based on the price action, without actually taking the trade. Of course, when done this way there's no certainty that the trade actually triggered.

NON-DETERMINISTIC APPROACH

If the deterministic approach described above is a go-no, then you'll need to get the algos to communicate with each other. You can do this using a number of Microsoft Windows inner-process-communication (IPC) methods.

I'll point out that IPC is non-trivial and error-prone, so if you can find a way to get the deterministic approach to work, that would be ideal.