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

Tick by Tick Stop Adjustment, Are you serious?

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

    Tick by Tick Stop Adjustment, Are you serious?

    Ok, I've played with this for weeks now, read and read and read.. and I just want to make sure my understanding of this is correct.

    Here's all I want to do.

    Backtesting/optimizing a strategy, I
    - Enter a trade based off of a 3min indicator, one contract,using a market order, with a 15 tick stop loss, no problem.
    - then, all I want to do, is if the price ever hits 5 ticks higher then the entry price adjust that stop loss to one tick above break even.
    -I've used firstickofbar which was a waste of time because COBC always equals true
    -I've tried various combinations of Barsinprogress and COBC, which is also of course useless
    -my best option is to dynamically manage a stoploss or trailstop, but this still will NEVER get me out of a trade intra candle. So if the price moves to +5 ticks, then drops in the same candle my stop will never get adjusted to breakeven+1 until after the candle, which is too late.

    So, I just want to make sure the only way to have a stop get adjusted tick by tick is to use "intrabar granularity" and Add(PeriodType.Tick,1) which makes backtesting an abosulte joke and I can stop wasting my time.

    Is this correct? Or is there a way to activate tick by tick processing just while a position is open to update stops?

    Thanks in advance,

    Wayne

    #2
    Why is COBC always true ?
    Could you reference an ATM template from your strategy?
    Last edited by stocktraderbmp; 03-25-2013, 04:56 PM.

    Comment


      #3
      Because I'm backtesting/optimizing, in which case COBC is always true for historical bars, even if set to false. At least that's how I understand it.

      Comment


        #4
        Originally posted by waynewright33 View Post
        Because I'm backtesting/optimizing, in which case COBC is always true for historical bars, even if set to false. At least that's how I understand it.
        I wasn't aware of that but will look into it now - may affect a few of my results - have you tried referencing an ATM template?

        Comment


          #5
          You are quite right - thank you for this nugget - have just read the help file on backtesting using the 3 data feeds possible - am going to do a bit more on it myself now. Need to find out if the ATM template is affected as well.

          Comment


            #6
            Yeah, quite annoying really, as COBC with historical bars would make this so much easier.

            I can almost get it with SetTrailStop, which works Tick by Tick, but I can't figure out how to UPDATE it tick by tick without add the 1 tick series.

            Comment


              #7
              Obviously I am unaware of your system, strategy and goals but could you change your 3min bar to a range bar of 4 ticks?

              Comment


                #8
                Hi guys, you're correct in understanding - COBC would be true for historical bar at all times, it would not have access to intrabar data per se. This would need to be added in via the Add() call, so then Exit methods could be dynamically updated. However this would not affect your Set()'s, as they will always work off the primary series only. Our next major platform update is planned to offer more options here to enhance and ease backtesting those cases.

                ATM's could be called in NinjaScript strategies as well via the AtmStrategyCreate() but could not be backtested, only realtime and Market Replay testing is possible here.
                BertrandNinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by tonynt, Yesterday, 01:48 PM
                2 responses
                10 views
                0 likes
                Last Post tonynt
                by tonynt
                 
                Started by goodknight777, Today, 08:43 AM
                1 response
                2 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by Salahinho99, 05-05-2024, 04:13 AM
                5 responses
                47 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by ttrader23, Yesterday, 09:04 AM
                7 responses
                34 views
                0 likes
                Last Post ttrader23  
                Started by damethetrader, Today, 08:31 AM
                1 response
                4 views
                0 likes
                Last Post NinjaTrader_Clayton  
                Working...
                X