Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Long Strategy Has Suddenly Been Trading Short This Last Week

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

    #16
    Originally posted by outstretchedarm View Post
    so whats the solution? how do I stop this from happening all the time.
    I do not know if you would like this hack, but what I did was to create yet another public Boolean property, RealTimeOnly, which enabled the bypass of Historical bars. Whenever my NT gets into that funky state where it is showing a yellow color for the Strategy, and I cannot get the fersluggin' thing to take a trade or not, I just enable the option, so that NT will ignore historical trade positioning and just trade already.

    Code:
    [FONT=Courier New][COLOR=#0000ff][FONT=Courier New][COLOR=#0000ff]if[/COLOR][/FONT][/COLOR][/FONT][FONT=Courier New][COLOR=#000000] ([/COLOR][/FONT][FONT=Courier New][COLOR=#0000ff][FONT=Courier New][COLOR=#0000ff]this[/COLOR][/FONT][/COLOR][/FONT][FONT=Courier New][COLOR=#000000].RealTimeOnly && Historical) [/COLOR][/FONT][FONT=Courier New][COLOR=#0000ff][FONT=Courier New][COLOR=#0000ff]return[/COLOR][/FONT][/COLOR][/FONT][FONT=Courier New][COLOR=#000000];[/COLOR][/FONT]
    right before my order management block does the trick.

    If I want to do analysis, such as BackTesting or Optimizing, I just turn the option off.

    Oftentimes, I find that after a day's trading with it turned on, I can turn it off anyway for real time trading too, and have NT start trading sensibly again. YMMV..
    Last edited by koganam; 01-22-2013, 10:53 PM.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    67 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    36 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    59 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    62 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    53 views
    0 likes
    Last Post CarlTrading  
    Working...
    X