Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy with renko..problem in backtest

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

    #31
    i read it...thanks...


    if (CrossAbove(Close,Open,1)) EnterLongStopLimit(Close[0]+1 * TickSize,Close[0]);
    else if (CrossBelow(Close,Open,1)) EnterShortStopLimit(Close[0]-1 * TickSize,Close[0]);


    ...

    Comment


      #32
      Originally posted by esignal View Post
      So are you now seeing the trades?

      Comment


        #33
        no....i don't see any trade ...

        Comment


          #34
          Originally posted by esignal View Post
          no....i don't see any trade ...
          Well, as I said, and have shown, that code works on my system. We have checked everything that I can check. If code that works on my system does not work on yours, and you say that there are no errors in your log, then someone will have to take a look at your particular system.

          You are going to have to send an email to NT support, requesting that someone took a look at your specific system remotely.

          Sorry that I cannot be of any further help.

          Comment


            #35
            now i see Ninjascript Output (usually i see Log)..

            In NinjaScript Output i see this error:



            Disabling NinjaScript strategy 'ntforumesignal/67481990'
            Strategy 'ntforumesignal/67481990': An order placed at '16/02/2016 00:03:00' has been ignored since the order was submitted before the strategy property BarsRequiredToTrade had been met.
            Enabling NinjaScript strategy 'ntforumesignal/67481990' : On starting a real-time strategy - StartBehavior=WaitUntilFlat EntryHandling=All entries EntriesPerDirection=1 StopTargetHandling=Per entry execution ErrorHandling=Stop strategy, cancel orders, close positions ExitOnSessionClose=True / triggering 30 seconds before close SetOrderQuantityBy=Strategy ConnectionLossHandling=Recalculate DisconnectDelaySeconds=10 CancelEntriesOnStrategyDisable=False CancelExitsOnStrategyDisable=False Calculate=On bar close IsUnmanaged=False MaxRestarts=4 in 5 minutes


            i repeat:

            i use NQ 03-16 (setting originally)





            with this code :


            #region Using declarations
            using System;
            using System.Collections.Generic;
            using System.ComponentModel;
            using System.ComponentModel.DataAnnotations;
            using System.Linq;
            using System.Text;
            using System.Threading.Tasks;
            using System.Windows;
            using System.Windows.Input;
            using System.Windows.Media;
            using System.Xml.Serialization;
            using NinjaTrader.Cbi;
            using NinjaTrader.Gui;
            using NinjaTrader.Gui.Chart;
            using NinjaTrader.Gui.SuperDom;
            using NinjaTrader.Data;
            using NinjaTrader.NinjaScript;
            using NinjaTrader.Core.FloatingPoint;
            using NinjaTrader.NinjaScript.Indicators;
            using NinjaTrader.NinjaScript.DrawingTools;
            #endregion
            //This namespace holds Strategies in this folder and is required. Do not change it.
            namespace NinjaTrader.NinjaScript.Strategies
            {
            public class ntforumesignal : Strategy
            {
            protected override void OnStateChange()
            {
            if (State == State.SetDefaults)
            {
            Description = @"Enter the description for your new custom Strategy here.";
            Name = "ntforumesignal";
            Calculate = Calculate.OnBarClose;
            EntriesPerDirection = 1;
            EntryHandling = EntryHandling.AllEntries;
            IsExitOnSessionCloseStrategy = true;
            ExitOnSessionCloseSeconds = 30;
            IsFillLimitOnTouch = false;
            MaximumBarsLookBack = MaximumBarsLookBack.TwoHundredFiftySix;
            OrderFillResolution = OrderFillResolution.Standard;
            Slippage = 0;
            StartBehavior = StartBehavior.AdoptAccountPosition;
            TimeInForce = TimeInForce.Gtc;
            TraceOrders = false;
            RealtimeErrorHandling = RealtimeErrorHandling.StopCancelClose;
            StopTargetHandling = StopTargetHandling.PerEntryExecution;
            BarsRequiredToTrade = 20;
            }
            else if (State == State.Configure)
            {
            }
            }
            protected override void OnBarUpdate()
            {
            //Add your custom strategy logic here.
            if (CrossAbove(Close,Open,1)) EnterLongStopLimit(Close[0]+1 * TickSize,Close[0]);
            else if (CrossBelow(Close,Open,1)) EnterShortStopLimit(Close[0]-1 * TickSize,Close[0]);
            }
            }
            }
            Last edited by esignal; 02-21-2016, 03:44 AM.

            Comment


              #36
              Originally posted by esignal View Post
              now i see Ninjascript Output (usually i see Log)..

              In NinjaScript Output i see this error:
              i repeat:

              i use NQ 03-16 (setting originally)





              with this code :
              Something strange this way walks. I tried this again, and was also no longer seeing any trades, so started troubleshooting. It would appear that The EntryStopLimit() orders may be processing funny. Try switching your order levels to see if you get the same results that I did.

              ref: http://ninjatrader.com/support/forum...ad.php?t=83322

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by TraderG23, 12-08-2023, 07:56 AM
              10 responses
              397 views
              1 like
              Last Post beobast
              by beobast
               
              Started by lorem, Yesterday, 09:18 AM
              5 responses
              19 views
              0 likes
              Last Post NinjaTrader_ChelseaB  
              Started by WHICKED, Today, 12:56 PM
              2 responses
              15 views
              0 likes
              Last Post WHICKED
              by WHICKED
               
              Started by Felix Reichert, Today, 02:12 PM
              0 responses
              4 views
              0 likes
              Last Post Felix Reichert  
              Started by Tim-c, Today, 02:10 PM
              0 responses
              6 views
              0 likes
              Last Post Tim-c
              by Tim-c
               
              Working...
              X