![]() |
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
|
|||||||
| 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. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Jul 2007
Location: Russia
Posts: 7
Thanks: 0
Thanked 0 times in 0 posts
|
I was wondering if there is a way to catch the end of a minute bar when updating a strategy on a tick per tick basis?
I explain: protectedoverridevoid Initialize() { .... Add(PeriodType.Minute,1); CalculateOnBarClose = false; } On the OnBarUpdate function, let say I want to compute and indicator only at the end of the minute bar serie, if I use I(BarsArray[1],some paremeters)[1] I will have the value of that indicator at the end of last bar. The value of the indicator for the current bar computed by I(BarsArray[1],some paremeters)[0] being updated at every tick. However the problem with this method is that I need to wait the first tick of the new bar to have the value of the previous finished 1 minute bar. Is there any other ways in Ninja to avoid my 1 tick delay and know that the current bar is finished, some form of EndOfBar finished event? That event could be triggered by some timer event. Thanks for the support. Fabrice. |
|
|
|
|
|
#2 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
Please see here: http://www.ninjatrader-support.com/v...ead.php?t=2571
Dierk
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Easiest way to check for last tick on a tick bar? | higler | General Programming | 8 | 02-28-2009 02:01 PM |
| Woodie's Pivots different on minute and tick charts. | laura | Charting | 11 | 09-06-2007 06:39 AM |
| Catch the end of a minute bar on a tick by tick OnBarUpdate event | Fabrice | Automated Trading | 5 | 07-06-2007 12:28 PM |
| Open tick to DOM | deanldavis475 | Connecting | 3 | 06-22-2007 08:11 AM |
| Tick counter gone? | LG | Charting | 2 | 02-06-2007 07:31 AM |