NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Strategy Development

Strategy Development Support for the development of custom automated trading strategies using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 10-02-2007, 07:31 AM   #1
bbarroux
Junior Member
 
Join Date: Oct 2007
Posts: 10
Thanks: 0
Thanked 0 times in 0 posts
Default Code->test/debug->change code->retest ... cycle process

Hi,

I'm facing what is probably a beginner issue, i searched the forum and documentation, but i couldn't find the solution. Sorry if this issue has already been discussed.

I'm developping a quite basic strategy, which is quite easy, thanks to the good code editor and the good documentation. However, I'm not comfortable with the testing/debugging process. I'm testing whith the simulated data feed. i'm using the strategy tab to launch my strategy, and when i want to change something, i stop the strategy, go back to the editor, change my code, compile again. Then if i restart the strategy, i have the feeling that it is still the old one being launched.
If i create a new strategy, the strategy tab quickly becomes a mess, and at some point, all i can do is restart NT.
Also, i'm not quite clear about when the "initialize" method is triggered. I have the feeling that it may be triggered a multiple time. I also noticed that when I'm launching a new strategy (in strategies tab), all my strategies initialize functions are triggered, whatever strategy I have chosen in the strategy launch window. this is a bit confusing.

So could you please give me an insight about what would be the best practice for this code - test -change -retest process?

Thank you in advance.

B.
bbarroux is offline  
Reply With Quote
Old 10-02-2007, 07:40 AM   #2
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Default

- Initialize() is called for any temporary strategy instance created.
- Restarting a strategy e.g. on chart will start a new version of your updated strategy.
NinjaTrader_Dierk is offline  
Reply With Quote
Old 10-02-2007, 10:41 AM   #3
bbarroux
Junior Member
 
Join Date: Oct 2007
Posts: 10
Thanks: 0
Thanked 0 times in 0 posts
Default

Hi Dierk,

Thank for answering me. If I do it from the chart window, I indeed don't have to deal with the mess generated in the strategies tab, which makes life much easier.

If I may suggest sthg, the process would be slightly easier if the strategy popup (in chart window) was not modal and/or if it kept the last parameters used when you start the strategy.

Regards,
Bertrand
bbarroux is offline  
Reply With Quote
Old 10-02-2007, 12:44 PM   #4
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Default

Thanks for your suggestions. We'll add them to the list.
NinjaTrader_Dierk is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
SMA code maxpi Indicator Development 5 07-29-2010 06:21 AM
why didn't this code work HelloHello Automated Trading 4 08-28-2007 12:03 PM
Compiling Code moflaherty Suggestions And Feedback 2 08-22-2007 07:23 PM
code question abikambic General Programming 2 05-03-2007 06:03 AM
Code sharing MrBaffalo Strategy Development 2 04-11-2007 04:46 AM


All times are GMT -6. The time now is 07:35 AM.