Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NT 6.5 V6 running great for me but this is wierd

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

    NT 6.5 V6 running great for me but this is wierd

    the following is enclosed in a simple if (trigger) structure.... i can see the settrailstop executed in the output window with trace on. but the enterlong never happens. I am running the strat on a one minute chart. Can anyone see what is wrong. Need I use an Entry Signal name? The same thing was happening in NT6.5 V5. I'm baffled.

    if (SLS == 2)
    {
    SetTrailStop(CalculationMode.Ticks, MyInit);
    SLS =
    1;
    }
    myEntry =
    0;
    SendMail(
    "[email protected]","[email protected]","Buy " + Instrument.MasterInstrument.Name,"Buy " + Instrument.MasterInstrument.Name + " at " + Close[0].ToString());
    EnterLong(DefaultQuantity,
    "");

    Thanks Gentlemen

    #2
    Please disregard past submission, i use mama indicator within strategy and also put on market analyzer to monitor.... analyzer says all are true yet strategy does not trigger events ??? bararray 1, 2, 3 are 30,60,90

    if (CrossAbove(StochRSI(BarsArray[0],7),RSIline,20)
    && MAMA(BarsArray[
    1],0.5,0.05).Default[0] > MAMA(BarsArray[1],0.5,0.05).Fama[0]
    && MAMA(BarsArray[
    2],0.5,0.05).Default[0] > MAMA(BarsArray[2],0.5,0.05).Fama[0]
    && MAMA(BarsArray[
    3],0.5,0.05).Default[0] > MAMA(BarsArray[3],0.5,0.05).Fama[0]

    Comment


      #3
      You will want to monitor the values of your condition directly from the strategy. Print out all those values and see if they are truly all true at the exact same time. Use Time[0] to timestamp your outputs.
      Josh P.NinjaTrader Customer Service

      Comment


        #4
        thanks for the advice josh, i think i nailed it. i run on a 1 minute chart but evaluate other bar arrays for signals. i figured that would be the best way to get the backtests as close as possible. backtest on 1 minute charts and use bararrays for signal logic right? my problem was i set the live on bar close when i really wanted onbarclose to be false. you think?
        thanks josh

        Comment


          #5
          one other quick question please, when using crossabove and crossbelow the look back period should mean true if crossed on any bar in the last n bars?

          Comment


            #6
            I cannot comment on which CalculateOnBarClose setting you should use because that depends on how you want your strategy to calculate. Calculating tick-by-tick is a performance hit though so use it only when you must.

            Your analysis of the lookback period on CrossAbove/Below is correct.
            Josh P.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by jpeep, 08-16-2020, 08:31 AM
            17 responses
            502 views
            0 likes
            Last Post notenufftime  
            Started by ETFVoyageur, 05-07-2024, 07:05 PM
            15 responses
            123 views
            0 likes
            Last Post ETFVoyageur  
            Started by esmall, Today, 07:14 PM
            0 responses
            9 views
            0 likes
            Last Post esmall
            by esmall
             
            Started by Option Whisperer, 05-09-2024, 07:58 PM
            6 responses
            26 views
            0 likes
            Last Post Option Whisperer  
            Started by rayyyu12, Today, 05:38 PM
            0 responses
            12 views
            0 likes
            Last Post rayyyu12  
            Working...
            X