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

Spread indicator - Automated

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

    Spread indicator - Automated

    Hi all,

    I am trying to place a short order automatically when the high of the spread indicator is above 0.0005

    Seems like i have everything setup correctly but for some reason its not working when i run it live.

    Calculation needs to be done on each tick and i have that selected.

    have included some images below.

    Anyone know why this is not working?

    Thanks in advance for any help.



    #2
    Hello jmahon,

    Thanks for your post.

    If your condition is not triggering an order then you would need to debug your strategy to find out why. In the strategy builder you can use a Print statement to output information to the New>Ninjascript output window. The Print statement in the strategy builder has a string builder which allows you to print text information and numerical values. I would suggest printing the values used in the condition that would place the order, in this case the value of the "SpreadHigh".

    Here is a short video that walks through building a print statement in the strategy builder to find in the example used when a bool changes from true to false. https://paul-ninjatrader.tinytake.co...NV8xMDk5MDc5Nw
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_PaulH View Post
      Hello jmahon,

      Thanks for your post.

      If your condition is not triggering an order then you would need to debug your strategy to find out why. In the strategy builder you can use a Print statement to output information to the New>Ninjascript output window. The Print statement in the strategy builder has a string builder which allows you to print text information and numerical values. I would suggest printing the values used in the condition that would place the order, in this case the value of the "SpreadHigh".

      Here is a short video that walks through building a print statement in the strategy builder to find in the example used when a bool changes from true to false. https://paul-ninjatrader.tinytake.co...NV8xMDk5MDc5Nw
      Thanks Paul, i will give this a try.

      Jack

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by daniel_weber8, Today, 01:21 PM
      1 response
      10 views
      0 likes
      Last Post NinjaTrader_ChristopherS  
      Started by jungsoohuh, Today, 12:07 PM
      1 response
      23 views
      0 likes
      Last Post NinjaTrader_PaulH  
      Started by SharonSS, Today, 11:54 AM
      1 response
      15 views
      0 likes
      Last Post NinjaTrader_Jim  
      Started by crystalet, Today, 11:20 AM
      3 responses
      17 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Started by SuperDude123, Today, 09:23 AM
      1 response
      34 views
      0 likes
      Last Post NinjaTrader_JustinD  
      Working...
      X