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

State.SetDefaults: NT8 Native list?

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

    State.SetDefaults: NT8 Native list?

    Hi there,

    I was exploring the strategy wizard in NT8 this evening, and State.SetDefaults looked like this at the end of it:

    Code:
    protected override void OnStateChange()
    		{
    			if (State == State.SetDefaults)
    			{
    				Description									= @"Trying this out...";
    				Name										= "SampleStrat";
    				Calculate									= Calculate.OnBarClose;
    				EntriesPerDirection							= 1;
    				EntryHandling								= EntryHandling.AllEntries;
    				IsExitOnSessionCloseStrategy				= true;
    				ExitOnSessionCloseSeconds					= 60;
    				IsFillLimitOnTouch							= false;
    				MaximumBarsLookBack							= MaximumBarsLookBack.TwoHundredFiftySix;
    				OrderFillResolution							= OrderFillResolution.Standard;
    				Slippage									= 0;
    				StartBehavior								= StartBehavior.WaitUntilFlat;
    				TimeInForce									= TimeInForce.Gtc;
    				TraceOrders									= false;
    				RealtimeErrorHandling						= RealtimeErrorHandling.StopCancelClose;
    				StopTargetHandling							= StopTargetHandling.PerEntryExecution;
    				BarsRequiredToTrade							= 10;
    			}
    			else if (State == State.Configure)
    			{
    			}
    		}
    After looking at this and browsing some forum threads/help guide, I'm wondering if there's a list of NT8 native settings that go in this space. Things like 'BarsRequiredToTrade' and 'ExitOnSessionCloseSeconds'. Since I work straight on the code, I'd prefer to know the entire sandbox.

    Is there such a reference, or is it a matter of exploring different categories above and seeing what those options are?

    I will say that... one of the infuriating and frustrating things about working with NT7 was the Help Guide having really cryptic, incomplete code samples and references. The NT8 guide is much better, but I'd still like to see some depth on configurable options like this.

    Thanks in advance for any help you can give.

    Yours,
    Spider

    #2
    Hello,

    Thank you for the post.

    The help guide does have a high-level overview of each different type, for example, Strategy : https://ninjatrader.com/support/help...s/strategy.htm

    Clicking on the Name of the type from the help guides left toolbar should produce a page like the one linked above listing most common inherited properties and methods for that type. This is a high-level overview, as you can see on the left toolbar there are still other areas under Strategy that can be expanded like Order Methods.

    Generally, we suggest that you explore the help guide as NinjaScript works a little different than just a programming language. This is the best way to learn how the various tools and parts of the platform can be controlled by NinjaScript and how they all work together. We do try to offer a large number of samples in various formats so each user can learn in their own comfort but there are still concepts which you may need to sit down and read to fully process.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Thanks Jesse! Exactly what I was looking for.

      And I understand re: exploring the Help Guide. I've been writing with NT for a while, but it's just the transition to the new environment that I'm catching up with. Appreciate your time.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by jeronymite, 04-12-2024, 04:26 PM
      3 responses
      40 views
      0 likes
      Last Post jeronymite  
      Started by bill2023, Today, 08:51 AM
      2 responses
      16 views
      0 likes
      Last Post bill2023  
      Started by sidlercom80, 10-28-2023, 08:49 AM
      167 responses
      2,260 views
      0 likes
      Last Post jeronymite  
      Started by warreng86, 11-10-2020, 02:04 PM
      7 responses
      1,362 views
      0 likes
      Last Post NinjaTrader_Manfred  
      Started by Perr0Grande, Today, 08:16 PM
      0 responses
      5 views
      0 likes
      Last Post Perr0Grande  
      Working...
      X