![]() |
|
|||||||
| General Programming General NinjaScript programming questions. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: Oct 2007
Posts: 1,862
Thanks: 16
Thanked 98 times in 81 posts
|
This is just a short question.
I understand that Plot() is executed as per Chart Properties -> Display Update Interval settings, which will avoid high CPU load. If I use DrawRectangle(), DtawLine() or any other Draw() method in OnBarUpdate(), will this be (a) calculated with every incoming tick and cause high processor load, if the indicator is set to CalcOnBarClose = false, or (b) filtered to comply with the Display Update Interval settings under chart properties. Thank you for your response. |
|
|
|
|
|
#2 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
Harry, I saw your thread on BigMike's ... I can't give you a definite answer, since what you are after is definitely beyond what we provide support for. This would require that you tested your approach under every potential situation...
However, here is some info: IndicatorBase.Plot() call frequency is primarily impacted by the chart update frequency. Although there might be additional situations where the chart (and indicators) would require repainting.
Dierk
NinjaTrader Customer Service |
|
|
|
|
|
#3 | |
|
Senior Member
Join Date: Oct 2007
Posts: 1,862
Thanks: 16
Thanked 98 times in 81 posts
|
Hi Dierk,
thanks for the answer, understood that for Plot() and it makes sense. Just wanted to know whether the Draw() methods react to every incoming tick, or if they are filtered as well. A "yes" or "no" would be fine. Otherwise I can do some tests to find out, but an answer would save me some time. Quote:
|
|
|
|
|
|
|
#4 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
The Draw() methods create objects which are redrawn whenever a chart is repainted which is triggered by logic below.
Obviously the Draw() methods in your code would be called whenever OnBarUpdate() is triggered which could be down to the tick (COBC=false). Hope this helps
Dierk
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Senior Member
Join Date: Oct 2007
Posts: 1,862
Thanks: 16
Thanked 98 times in 81 posts
|
Thanks for the information, that was helpful.
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Allow quicker chart display update interval | Softturbo | Version 7 Beta General Questions & Bug Reports | 25 | 06-10-2010 04:34 PM |
| Display Update Interval | dkelly | Version 7 Beta General Questions & Bug Reports | 1 | 05-04-2010 01:00 PM |
| Idea: Display update interval (sec) | David Lean | Suggestions And Feedback | 1 | 12-08-2009 05:53 AM |
| Does Display Update Interval Indirectly Control OnBarUpdate? | kcsystemtrader | Strategy Development | 1 | 02-12-2009 01:26 PM |
| Display Update Interval (sec) question. | higler | Charting | 1 | 07-30-2007 06:32 AM |