Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Nt8b11 Issue with properties in optimization

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

  • NinjaTrader_ZacharyG
    replied
    Hello ToMer_K,

    Thank you for writing in.

    Can you please provide the strategy that is displaying this behavior so I may test for this behavior on my end?

    To export your script do the following:

    1. From the Control Center window select the menu Tools > Export > NinjaScript... to open the "Export NinjaScript" dialog window

    2. Press "add"

    3. Use the "Type" drop down to filter available NinjaScript types

    4. Select all of the files that you want to export and press the "OK" button

    5. A list of all files that will be exported will be shown

    6. Press the "Export" button to export the selected files

    7. A NinjaScript Archive File (.zip) file will be created in My Documents\<NinjaTrader Folder>\bin\Custom\ExportNinjaScript. You can press ".." and change the export directory if you wish

    Once exported, please attach the file as an attachment to your reply.

    Below is a link to the help guide on Exporting NinjaScripts:


    If you would rather not provide your strategy on the support forum, please email the exported zip to platformsupport [AT] ninjatrader [DOT] com with both my name and a link to this thread referenced.

    I look forward to receiving the export.

    Leave a comment:


  • ToMer_K
    started a topic Nt8b11 Issue with properties in optimization

    Nt8b11 Issue with properties in optimization

    Hi,
    It seems that the strategy analyzer has a "memory" of which variable names I used when I first started working with it.

    If I add a property to my strategy the optimizer doesn't add the option to iterate over the new variable.

    For example, I have "Contracts" and "Reversal" properties which are iterable and and I add a new one "TrailingStop" and there is no option to iterate over it. I tried changing the name or adding other properties but the only ones that I can use are the first 2.

    I tried restarting the strategy analyzer and it didn't help.

    The Properties code:
    Code:
    		[Range(1, int.MaxValue)]
    		[NinjaScriptProperty]
    		[Display(ResourceType = typeof(Custom.Resource), Name="Contracts", Description="Amount of contracts", Order=1, GroupName="NinjaScriptStrategyParameters")]
    		public int Contracts
    		{ get; set; }
    		
    		[Range(1, int.MaxValue)]
    		[NinjaScriptProperty]
    		[Display(ResourceType = typeof(Custom.Resource), Name="TrailingStop", Description="Kagi reverse after x ticks", Order=2, GroupName="NinjaScriptStrategyParameters")]
    		public int TrailingStopTicks
    		{ get; set; }
    		
    		[Range(0, int.MaxValue)]
    		[NinjaScriptProperty]
    		[Display(ResourceType = typeof(Custom.Resource), Name="Reversal", Description="Trailing Stop Ticks", Order=3, GroupName="NinjaScriptStrategyParameters")]
    		public int RevTicks
    		{ get; set; }
    Attached Files

Latest Posts

Collapse

Topics Statistics Last Post
Started by alifarahani, Today, 09:40 AM
6 responses
30 views
0 likes
Last Post alifarahani  
Started by Waxavi, Today, 02:10 AM
1 response
17 views
0 likes
Last Post NinjaTrader_LuisH  
Started by Kaledus, Today, 01:29 PM
5 responses
13 views
0 likes
Last Post NinjaTrader_Jesse  
Started by Waxavi, Today, 02:00 AM
1 response
12 views
0 likes
Last Post NinjaTrader_LuisH  
Started by gentlebenthebear, Today, 01:30 AM
3 responses
17 views
0 likes
Last Post NinjaTrader_Jesse  
Working...
X