PDA

View Full Version : Way to reset strategy/account positions?


Jeremytang
10-06-2010, 11:06 AM
Hi,

I had a strategy that had some errors with serialization, causing NT to shut down unexpectedly. I've since fixed those errors, but noticed that one my symbols (NG) is now consistently out of sync with any strategy I run.

Is there a way to wipe the slate clean and somehow reset the position information for a particular symbol?

Jeremy

NinjaTrader_RyanM
10-06-2010, 11:14 AM
Hello Jeremy,

The strategy position is generated by the signals of the strategy. There's no way to state it explicitly.

You may consider adding the following lines to your strategy, which means it only runs on real time data. With this the strategy won't run on historical data and should then be in a flat state at the start.

if (Historical) (http://www.ninjatrader-support.com/HelpGuideV6/Historical.html)
return; (http://www.ninjatrader-support.com/HelpGuideV6/Historical.html)

MKTTHOTS
10-12-2010, 08:08 AM
Hi,
I have a question relating to reconcilliation between STRATEGY position and ACCOUNT position. I understand the concept and operation of Strategy vs. Account. What I would like to do is to generate an ALERT or NOTICE (such as an email) when the Strategy is out of Sync with Account positions?
With thanks in advance,
MT

NinjaTrader_RyanM
10-12-2010, 08:30 AM
Hello MKTTHOTS,

Unfortunately this is something that would have to be monitored manually. There aren't built in NinjaScript methods that can access your account position.

MKTTHOTS
10-12-2010, 08:32 AM
Thanks Ryan & understood. Question, what is the best way to monitor this in your opinion?

NinjaTrader_RyanM
10-12-2010, 08:37 AM
You can use the NinjaTrader control center for this. The strategies tab will show your strategy position. The positions tab will show account positions.

millridge
12-12-2010, 08:51 PM
How come I don't get the strategy position under strategy tab? The account position under position tab looks fine. I am running NT7.0.1000.1. with IB connection.

millridge
12-12-2010, 09:17 PM
never mind, I found the reason.

NinjaTrader_Bertrand
12-13-2010, 06:50 AM
Glad you got it resolved, for more info on different sync options in NT7 please see this article from the helpguide - http://www.ninjatrader.com/support/helpGuides/nt7/syncing_account_positions.htm