|
Attention! Read the forum rules carefully before posting a topic.
Try to find an answer in Wiki before asking a question. Submit programming questions in this forum only. Off topics are strictly forbidden.
Any topics which do not satisfy these rules will be deleted.
Updating indicator values every tick |
rounder8
|
Post subject: Updating indicator values every tick |
Post rating: 0
|
Posted: Mon 19 Mar, 2012, 23:30
|
|
User rating: 0
Joined: Sun 18 Mar, 2012, 17:13 Posts: 4
|
Hi,
Can I have an example code how to update indicator values on every tick? I tried to calculate indicator values using shift 0 but that yields NaN. Shift 1 gives the value of last bar I guess. So basically I want to see indicator values intra-bar...
|
|
|
|
 |
rounder8
|
Post subject: Re: Updating indicator values every tick |
Post rating: 0
|
Posted: Tue 20 Mar, 2012, 15:01
|
|
User rating: 0
Joined: Sun 18 Mar, 2012, 17:13 Posts: 4
|
Nevermind, I figured this one out. To get updates tick-by-tick on custom timeframes you need to first subscribe to the feed in onStart method.
|
|
|
|
 |
Tinfx
|
Post subject: Re: Updating indicator values every tick |
Post rating: 0
|
Posted: Sat 14 Jul, 2012, 19:24
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Hello rounder8
Any chance you could put some dummy code up for this. I am trying to calculate the value of an MA onTick and not getting the method to execute.
Any help greatly appreciated.
Tin
|
|
|
|
 |
API Support
|
Post subject: Re: Updating indicator values every tick |
Post rating: 0
|
Posted: Mon 16 Jul, 2012, 07:17
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
Please provide you example strategy and describe the launch case.
|
|
|
|
 |
Tinfx
|
Post subject: Re: Updating indicator values every tick |
Post rating: 0
|
Posted: Mon 16 Jul, 2012, 12:13
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Hello
So quite simply, for a short period from say 01/07/2012 12:00:00.000 to 01/07/2012 13:00:00.000 calculate EMA (14) for every tick and print values for 2 'before' and 1 tick 'after'. So, not at the onBar level, but on the onTick level.
T
|
|
|
|
 |
API Support
|
Post subject: Re: Updating indicator values every tick |
Post rating: 0
|
Posted: Mon 16 Jul, 2012, 12:42
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
|
|
|
 |
|
Pages: [
1
]
|
|
|
|
|