|
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.
Renko - MA calc out by one |
Tinfx
|
Post subject: Renko - MA calc out by one |
Post rating: 0
|
Posted: Wed 04 Jul, 2012, 10:54
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Wed 04 Jul, 2012, 14:22
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Wed 04 Jul, 2012, 23:26
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Many thanks for your help so far. I looked through the wiki's and checked charts params, gmt issue and used OHLC. I still think the same... I have recreated the problem I am having... I think the onBar print is out by one candle. When the 21:38 bar was printed, the onBar print was for 21:00 as per results below, which are from OutByx file attached. Results summary are index//time//ema//onBar print statement match (see log - OutByx) 85//21:38 // 1.02774 // none 84// 21:00 // 1.02776 // [0] 1.02776 83// 21:54 // 1.02782 // [1] 1.02782 82// 21:53.363 // 1.02785 // [2] 1.02785 81// 21:53.361 // 1.02786 // [3] 1.02786 This is the same problem experienced by dyscan in post of 18 Jun, 2012, 23:14 - viewtopic.php?f=7&t=47370&p=65115&hilit=simple+renko#p65115. Is there any way to get the extra data - can I use candleAfter? Also in the log file you will see some 'LoadDataAction' error. Not sure how to deal with this. Hope to have this resolved soon. Tin
Attachments: |
OutByx.rtf [8.48 KiB]
Downloaded 300 times
|
Chart_AUD_USD_Ticks_snapshot.png [142.47 KiB]
Downloaded 351 times
|
RenkoMAOutByOne.java [7.15 KiB]
Downloaded 291 times
|
Main.java [5.03 KiB]
Downloaded 293 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Thu 05 Jul, 2012, 12:34
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
Tinfx wrote: Is there any way to get the extra data - can I use candleAfter? Yes change candlesAfter to 1, because in IRenkoBarFeedListener.onBar you receive the bar that just has finished - the new bar has already started to form.
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Thu 05 Jul, 2012, 12:50
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Thanks
If I change candlesAfter to 1, is the output still in the same array and at [0]?
T
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Thu 05 Jul, 2012, 13:03
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
Just test it 
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 08:03
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Hello
I still have the same issue. I have set candlesBefore = 2 candlesAfter = 1, LAST =2, PREV =1 and SCND_LAST =0.
A the formation of the current 'open' candle, the print statement is for the previous candle with the values commencing from this previous candle. It must be possible to access the current EMA as the value is shown on the hart.
Can you pls assist.
T
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 08:14
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
Pardon, where is the problem and what is the question?
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 08:35
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
The question is, how do I get the ema of the current open bar and not the previous bar. I am using the attached code.
Attachments: |
RenkoMAOutByOne.java [7.15 KiB]
Downloaded 306 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 08:40
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
either by calling indicator with shift=0 or with your current approach, take the following element: maOutput[maOutput.length -1].
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 10:00
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Sorry and thanks for persevering ... but I have have printed maOutput[maOutput.length -1] and it's the same as the EMA of the last bar and not current - see below
2012-07-06 08:50:09.343 ma output line for last 3 range bars: [1.0272535151446864, 1.0271930464587282, 1.0271406402642311] 2012-07-06 08:50:09.343 1.0271406
Attachments: |
RenkoMAOutByOne.java [7.52 KiB]
Downloaded 303 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Fri 06 Jul, 2012, 10:08
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
And bizzarely, sometimes they are elements from 2 bars back. Like just now I get
2012-07-06 08:56:48.425 ma output line for last 3 range bars: [1.0272925174909227, 1.0272535151587996, 1.0271930464709595] 2012-07-06 08:56:48.425 1.027193. I am not sure if this has anything to do with it, but if you look at the table data for the renko feed, the bar at 2012-07-06 08:56:48.425 has an open and close price of 1.0268, which is incorrect.
But my main problem is still, I cannot access the current ema.
Attachments: |
Chart_AUD_USD_Ticks_data.csv [13.4 KiB]
Downloaded 295 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Mon 09 Jul, 2012, 14:45
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Hello
Is there any feedback on this?
T
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Tue 10 Jul, 2012, 13:39
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
This should get fixed with JForex-API 2.6.73
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Tue 10 Jul, 2012, 13:48
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
Great - Moosic to my ears. Dare I ask when 2.6 .73 is scheduled for release.
T
|
|
|
|
 |
API Support
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Tue 10 Jul, 2012, 13:56
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
|
|
|
 |
Tinfx
|
Post subject: Re: Renko - MA calc out by one |
Post rating: 0
|
Posted: Tue 10 Jul, 2012, 14:43
|
|
User rating: 0
Joined: Sun 22 Apr, 2012, 19:19 Posts: 54 Location: United KingdomUnited Kingdom
|
|
|
|
 |
|
Pages: [
1
]
|
|
|
|
|