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 > Application Technical Support > Automated Trading

Automated Trading Support for automated trading systems using NinjaScript. Support for our ATI (Automated Trading Interface) used to link an external application such as TradeStation and eSignal to NinjaTrader.

Reply
 
Thread Tools Display Modes
Old 02-25-2012, 11:08 PM   #1
zehua
Member
 
Join Date: Feb 2009
Posts: 82
Thanks: 1
Thanked 1 time in 1 post
Default Confused on strategies tab--ninjascript

I read the following but still don't understand what it is saying. Could anyone help me understand it please?

Wait until flat before executing live:
When starting a NinjaScript strategy that relies on historical data for calculating its current positions and order states, it will wait until the strategy position has reached or crossed a flat position before executing any live orders. All trading done before this condition will be virtual, simulated trades.
Immediately submit live working historical orders:
When starting a NinjaScript strategy that relies on historical data for calculating its current position and orders states, it will immediately submit live any working orders that reflect the current strategy's overall order state. It is IMPORTANT to understand that the position of the strategy reported in the Strategies tab may not reflect the actual account-based position reported in the Accounts tab at the time the strategy is started. In this scenario, it is highly recommend that the account position be synced to the strategy position.
zehua is offline  
Reply With Quote
Old 02-26-2012, 02:59 PM   #2
NinjaTrader_AdamP
NinjaTrader Customer Service
 
NinjaTrader_AdamP's Avatar
 
Join Date: Aug 2011
Location: Denver, CO, USA
Posts: 2,895
Thanks: 241
Thanked 375 times in 365 posts
Default

zehua,

Have you read this article in the help guide as well?

http://www.ninjatrader.com/support/h..._positions.htm
NinjaTrader_AdamP is offline  
Reply With Quote
Old 02-26-2012, 07:59 PM   #3
zehua
Member
 
Join Date: Feb 2009
Posts: 82
Thanks: 1
Thanked 1 time in 1 post
Default

Thanks Adam. After reading that a couple times, I now seem to understand it. I will read again when I am ready to test live trading.
zehua is offline  
Reply With Quote
Old 04-05-2012, 09:33 AM   #4
coolmoss
Senior Member
 
Join Date: Dec 2007
Posts: 365
Thanks: 36
Thanked 28 times in 24 posts
Default

As a follow up, could someone please clarify this statement: "...wait until the strategy position has reached or crossed a flat position..."

In particular, I'm focused on the word "crossed". I have a strategy that is designed to reverse, but during the process from going say, long to short, there is a very brief moment where the strategy is flat. I imagine we're talking a second, maybe more, maybe even less. I need to be able to shut off the strategy, for example during a news event, and then turn it back on. The strategy is almost always in a position.

So, my question is: is the very brief FLAT period during the transition from being long to going short in the strategy, enough FLAT time to let live orders execute again?

Thanks for your help.
coolmoss is offline  
Reply With Quote
Old 04-05-2012, 10:00 AM   #5
NinjaTrader_RyanM
NinjaTrader Customer Service
 
NinjaTrader_RyanM's Avatar
 
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
Default

Hi coolmoss,

Yes, that brief amount of time is enough for it to cross flat. The reversal is handled with two separate orders. Your position will be momentarily flat after the closing order for the virtual position. The strategy will then submit the entry order as a live order.
NinjaTrader_RyanM is offline  
Reply With Quote
The following user says thank you to NinjaTrader_RyanM for this post:
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
How to save list of strategies in Strategies tab gmiranda Miscellaneous Support 1 12-03-2011 01:49 PM
Error loading strategies in control panel strategies tab using NT7 rev 7 AlexJetski Version 7 Beta General Questions & Bug Reports 2 02-01-2010 12:35 PM
How to retain strategies in strategies tab tjendra Automated Trading 1 06-24-2009 10:56 AM
Saving Strategies on the Strategies Tab monti1a Automated Trading 4 05-08-2009 10:16 AM
Clearing old strategies from the strategies tab? mazachan Miscellaneous Support 1 07-10-2007 06:10 PM


All times are GMT -6. The time now is 11:11 PM.