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

Issue with ExitShortLimit

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

    Issue with ExitShortLimit

    Hello,

    I have a strategy in which I enter short positions using EnterShortLimit and exit those positions using ExitShortLimit. Once the very first short position is taken in the chart while back testing it using daily data, I found that it doesn't exit the short position at the appropriate bar, and instead exits the position after another couple of bars more. In the remaining short trades, it does seem to exit at the appropriate bar.

    On debugging with Print, I found that, the ExitShortLimit function does get executed in the appropriate bar. On printing the Error value, it gives NoError. But there is no action (i.e., the short position doesn't get exited). In all the remaining bars, the same thing happens, and after a few more bars, the position finally does get exited. I am not sure how to correct this problem. Can you please let me know what can be the problem.

    #2
    Hello,

    Thanks for your post.

    I would like to take a look at your script and test this behavior on my end.

    Please write in to PlatformSupport(at)NinjaTrader(dot)com and reference this forum post.

    You can attach your script to your email by going to File > Utilities > Export NinjaScript > Export selected source files > select your script > select the right arrow > Export. The file will be located under (My) Documents\NinjaTrader 7\bin\Custom\ExportNinjaScript.

    I look forward to assisting you with this matter.
    Josh G.NinjaTrader Customer Service

    Comment


      #3
      Hello NinjaTrader_Josh,

      Thank you for the help. I have mailed the script to you at PlatformSuppor[at]ninjatrader[dot]com along with the other relevant files (i.e., ninjascript file along with input data, output, screenshot of the chart).

      Thanks
      Last edited by NinjaTrader_PatrickH; 01-05-2018, 08:45 AM.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by The_Sec, Yesterday, 03:37 PM
      1 response
      11 views
      0 likes
      Last Post NinjaTrader_Gaby  
      Started by vecnopus, Today, 06:15 AM
      0 responses
      1 view
      0 likes
      Last Post vecnopus  
      Started by Aviram Y, Today, 05:29 AM
      0 responses
      5 views
      0 likes
      Last Post Aviram Y  
      Started by quantismo, 04-17-2024, 05:13 PM
      3 responses
      27 views
      0 likes
      Last Post NinjaTrader_Gaby  
      Started by ScottWalsh, 04-16-2024, 04:29 PM
      7 responses
      36 views
      0 likes
      Last Post NinjaTrader_Gaby  
      Working...
      X