Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Simulated Position

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Simulated Position

    Hello,

    before answering the question please notice that I work with 2 computers, one for longs and one for shorts with different accounts (otherwise it would be clear of course)

    how can I avoid long and a short at the same time. What can I do and code in the script eg on my computer with the long trades so that it doesn´t take a long trade when there would be a short running (so that maybe only the longs are sent to broker.?)

    Thanks
    Tony

    #2
    Tony, unfortunately strategies would per default not cross communicate and this would include communication to another instance running on another PC. You could look into keeping a log of open trades accessible through the network for example via a text file, but that would be something we could not support creating with C#.

    Comment


      #3
      Bertrand, thank you for your reply. Of course we can not code in the script that 2 computers computer communicate - not yet;-)

      I do the question different: Can I code so that NinjaTrader handles a trade as a position but it is not sent to brokers server? Like sim-mode for stops?

      Thanks
      Tony

      Comment


        #4
        Hi Tony, that would be done with NT simply trading in simulation so executing to the Sim101 account, that would be then only a simulated position - however you could not switch accounts dynamically from the strategy code.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by kinfxhk, 07-14-2026, 09:39 AM
        0 responses
        90 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 07-13-2026, 10:18 AM
        0 responses
        92 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 07-13-2026, 09:50 AM
        0 responses
        70 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 07-13-2026, 07:21 AM
        0 responses
        87 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 07-11-2026, 02:11 AM
        0 responses
        64 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Working...
        X