Can someone explain under what circumstances you would need to utilize the Update() method? Specifically is there ever a case where one would need to use the Update() method to get the correct (meaning updated) indicator's value when calling it from within another indicator or strategy calculation step?
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Update()- When is it necessary?
Collapse
X
-
Update()- When is it necessary?
I have read several posts from Josh on the Update() method but want to make sure I understand WHEN it is necessary if one is only needing to use an indicator's value itself and not an internal variable value within the indicator.
Can someone explain under what circumstances you would need to utilize the Update() method? Specifically is there ever a case where one would need to use the Update() method to get the correct (meaning updated) indicator's value when calling it from within another indicator or strategy calculation step?Tags: None
-
Update is needed any time you are accessing a "non-dataseries" property. DataSeries syns themselves by triggering OnBarUpdate if needed. But if you want access e.g. a custom property which holds the result of some calculation triggers in onBarUpdate, then you would need to make sure OnBarUpdate is triggered by calling Update().
-
Plots and Dataseries Don't require Update() 'call'?
Thanks Dierk,
just to make sure I am getting it, is this correct:
Plots and Data series values (in indicators) do NOT ever require an Update) explicitly because they update on each OnBarUpdate or during each tick (if OnBarUpdate = false).
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by rocketman7, Today, 02:12 AM
|
5 responses
23 views
0 likes
|
Last Post
by rocketman7
Today, 08:19 AM
|
||
Started by trilliantrader, 04-18-2024, 08:16 AM
|
7 responses
28 views
0 likes
|
Last Post Today, 07:56 AM | ||
Started by samish18, 04-17-2024, 08:57 AM
|
17 responses
66 views
0 likes
|
Last Post Today, 07:51 AM | ||
Started by briansaul, Today, 05:31 AM
|
1 response
15 views
0 likes
|
Last Post Today, 07:36 AM | ||
Started by PaulMohn, Today, 03:49 AM
|
1 response
12 views
0 likes
|
Last Post Today, 07:36 AM |
Comment