Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Ending strategy once day profit target hit?

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

    Ending strategy once day profit target hit?

    Hi,
    Been playing with ninja for awhile but just recently got around to messing with the strategy tester.
    I wanted to know if there was a way, for example, to end trading once $x profit was hit? I see you can set it to cap each trade at a certain profit as an exit strategy, however I am not able to figure out how to just have it use a dollar amount as a trading end time.
    Thanks for any help

    #2
    Please check out these reference samples: http://www.ninjatrader-support.com/v...ead.php?t=4084
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Thank you very much Josh, I will take a look at those and see if I can figure them out.
      I have another question in the meantime however.
      I am trying to get an exit strategy working, and not having much luck.
      It's basic, when the close of a bar is 10 ticks higher than the sma, close the short, when close is 10 ticks lower than the sma, close the long.
      I have only been using the wizard until now, as this is very new to me, and have tried quite a few times to get it working, but not working quite right yet.
      I have tried when close +10 < sma then exit, and close -10 > sma then exit, not quite right
      also tried close +10 crosses under sma etc still not working.
      I am using the offset field as it's the only place i see where I might add those 10 ticks, and have tried on both the close parameter and the sma parameter. Also tried setting the offset as price instead of ticks.

      I can give exact details if you need them, as to the example where it's not working, but hopefully you know what I am doing wrong without alot more detail (you seem to know your stuff so I am sure you are already typing )
      Thanks again!

      Comment


        #4
        You want to do it like these screenshots. For the Exit order you want to match it to your entry order's signal name.
        Attached Files
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Josh,
          That is exactly how I had it, but it was exiting incorrectly.
          Also, the example you gave was for exiting the short, but you had +10 offset. If I wanted the short exited only when the close price was 10 ticks above the sma, wouldn't I have to subtract 10 ticks from the close price in order to get this?

          Also, the setting for exiting long, the offset would be opposite right?

          Comment


            #6
            It depends what you want. Take a calculator to both sides and determine what you want in terms of + or -.

            Please describe why you feel it is exiting incorrectly? The picture I have shown will exit the short position if the closing price is 10 ticks above the SMA value. Let us say the close price is 100 and the SMA price is 99.99 right now. According to our example 100 + 0.10 = 100.1. That is > 99.99 so we will exit short.

            Your orders will exit/enter exactly whenever your condition evaluates to true. It is easiest just to use a calculator and run through some examples by hand with pen and paper to see exactly what values and how your conditions interact.
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              Thanks Josh,
              For some reason, I didn't change a thing but now it is working correctly. The platform did get laggy on me last night and actually ended up crashing and I had to start it up again. Maybe it was just a fluke with the platform.
              Anyhow, thanks for your help, I had it correct the entire time but apparently the strat tester just wasn't running properly at the time.

              Thanks for the wonderful support!

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by andrewtrades, Today, 04:57 PM
              1 response
              8 views
              0 likes
              Last Post NinjaTrader_Manfred  
              Started by chbruno, Today, 04:10 PM
              0 responses
              6 views
              0 likes
              Last Post chbruno
              by chbruno
               
              Started by josh18955, 03-25-2023, 11:16 AM
              6 responses
              436 views
              0 likes
              Last Post Delerium  
              Started by FAQtrader, Today, 03:35 PM
              0 responses
              7 views
              0 likes
              Last Post FAQtrader  
              Started by rocketman7, Today, 09:41 AM
              5 responses
              19 views
              0 likes
              Last Post NinjaTrader_Jesse  
              Working...
              X