Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

stop and reverse

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

    stop and reverse

    How does a stop and reverse scenario play out when running strategies? If I'm short and an order is sent out to go long 2 contracts will that result in being long 1 contract or being long 2 contracts? In other words, does the short need to be exited before a long order will be accepted or is the short exited when a long order is sent out or is the short offset by the number of long contracts filled? Basically, what is the most efficient way to get from being short 1 contract to being long one contract when i want to "stop and reverse" an existing short position?
    Last edited by gordongekko; 02-21-2018, 02:35 PM.

    #2
    Hello gordongekko,

    Thanks for your post.

    That is correct, if you are long and what to reverse, 1 short would close the long position and another short would leave you in a short position.

    The methods EnterLong() and EnterShort() will do reversing. You can see an example of use with the strategy SampleMACrossover in your NinjaTrader. There are only two conditions, there are only two entry orders needed.

    The EnterLong() and EnterShort() method determine if an existing position in the opposite direction exists and if so will place two orders one to close the opposite direction and one to put you in the new direction. Using these methods would be the most efficient as they use market orders that are filled immediately.
    Paul H.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by f.saeidi, Today, 07:07 AM
    6 responses
    19 views
    0 likes
    Last Post f.saeidi  
    Started by cmtjoancolmenero, Today, 02:31 PM
    6 responses
    14 views
    0 likes
    Last Post cmtjoancolmenero  
    Started by Graci117, Yesterday, 11:40 PM
    5 responses
    26 views
    0 likes
    Last Post NinjaTrader_BrandonH  
    Started by rene69851, Today, 03:25 PM
    0 responses
    3 views
    0 likes
    Last Post rene69851  
    Started by Irukandji, Yesterday, 05:50 AM
    3 responses
    9 views
    0 likes
    Last Post NinjaTrader_ChristopherJ  
    Working...
    X