![]() |
|
|||||||
| General Programming General NinjaScript programming questions. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: Jan 2008
Posts: 257
Thanks: 0
Thanked 0 times in 0 posts
|
Hello,
When is OnBarUpdate() called when the "CalculateOnBarClose" property is set to true? For example, in realtime, the first tick happened at 02:05:000, when would OnBarUpdate() corresponding to the 60Minute bar ( from 01:00:000 to 01:59:999 ) is called? Is it called at 02:00:000 after NT7 detecting the localtime or server time had passed 02:00:000 or it would wait for the first tick of next hour which was five seconds later than 2 O'Clock? - Clearpicks |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2009
Location: Denver, CO
Posts: 8,117
Thanks: 249
Thanked 418 times in 415 posts
|
Hello ClearPicks,
Please see here for how chart bars are built: http://www.ninjatrader.com/support/h..._are_built.htm With CalculateOnBarClose = true, the bar is closed as soon as the first tick of the new bar arrives. Next bar open and prior bar close are the same event.
Ryan M
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Timing sequence for "OnBarUpdate=True" | AnotherTrader | Automated Trading | 3 | 08-06-2010 07:00 AM |
| Editable "custom tag" property for each chart/window (for use with virtual desktops) | betaride | Suggestions And Feedback | 1 | 02-03-2010 06:26 AM |
| Is there a property like the "BarsSinceSession" that returns Grand Total Bar Nbr? | ChiTrader2000 | Strategy Development | 4 | 12-23-2009 01:46 PM |
| Possible to set "ByStrategyPosition" or "PerEntryExecution" in strategy? | kcsystemtrader | Strategy Development | 3 | 04-23-2009 09:54 AM |
| Indicator line goes to zero when CalculateOnBarClose set to True | ThePatientOne | Indicator Development | 1 | 08-30-2007 11:42 AM |