|
mismtach between Renko bar's data on chart and within strategy |
tcsabina
|
Post subject: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 09 Jan, 2014, 23:44
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Dear Support, Or anyone else, who played around with Renko bars. I have a little issue with a strategy that prints a Renko bar's details (start-, end time, OHLC, etc.). As visible on the attached screenshot, the data on the Historical Tester's chart is not matching the data the is printed by the strategy. The different is in the start- and end times.  Why do I have such difference?
Attachments: |
File comment: strategy that prints Renko bar details
RenkoTest.java [1.76 KiB]
Downloaded 298 times
|
Screenshot from 2014-01-09 23:38:16.png [178.43 KiB]
Downloaded 713 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.
|
|
|
|
|
 |
velldes
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Fri 10 Jan, 2014, 18:58
|
|
User rating: 1
Joined: Sun 20 May, 2012, 09:29 Posts: 22 Location: Czech Republic, programmer
|
|
|
|
 |
API Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Tue 14 Jan, 2014, 15:42
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
We could not reproduce this, please make sure that the on-chart feed and the strategy feed parameters do match.
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Tue 14 Jan, 2014, 23:31
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
On the chart I am using a 10 pips custom Renko period. In the strategy I am using: public IFeedDescriptor renkoFeedDescriptor = new RenkoFeedDescriptor(Instrument.EURUSD, PriceRange.FIVE_PIPS, OfferSide.ASK);
as I don't know how the define the 10pips range. However upon strategy start I am able to set 10pips: 22:29:07 Strategy "RenkoTest" Strategy ID: A07698C0FFB9AB83CCB0CB50A4EC5AD0 is started at 2014-01-14 22:29:07.668 GMT on the local computer with parameters ""=[FeedDescriptor [dataType=RENKO, instrument=EUR/USD, offerSide=Ask, period=7 Days, priceRange=10_PIPS, ]]
So I think I am using the same feed, right?
|
|
|
|
 |
hebasto
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 1
|
Posted: Wed 15 Jan, 2014, 08:34
|
|
User rating: 96
Joined: Mon 09 Sep, 2013, 07:09 Posts: 287 Location: Ukraine, SHostka
|
|
|
|
 |
API Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Wed 15 Jan, 2014, 09:13
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
You can create 10 pips by using the PriceRange.valueOf method.
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Wed 15 Jan, 2014, 15:11
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Thanks hebasto, I'll give it a try!
@Support: Do you think it will make any difference? The strategy is starting with 10pips as configured Renko bar parameter, as visible on the quoted start message. That is just cosmetic to change the default parameter to 10pip instead of 5pip. Are you able to replicate the issue? Or for you the chart and the strategy generates the same results?
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Wed 15 Jan, 2014, 22:19
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Dear Support, I've made little modification in the strategy. Using now context.subscribeToRenkoBarFeed. Result is still bad. There is still a difference in the start- and end-time of the Renko bars between the strategy's calculation and the chart's value. Also, Volume is bad.  Please take a look on this. It is hard to believe that you cannot replicate this. Simply start the strategy in the Historical Tester...
Attachments: |
File comment: screenshot with the problem
Screenshot from 2014-01-15 22:14:38.png [176.94 KiB]
Downloaded 821 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.
|
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Wed 15 Jan, 2014, 22:20
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Here is the slightly modified strategy.
Attachments: |
RenkoTest.java [2.32 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.
|
|
|
|
|
 |
hebasto
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Wed 15 Jan, 2014, 23:33
|
|
User rating: 96
Joined: Mon 09 Sep, 2013, 07:09 Posts: 287 Location: Ukraine, SHostka
|
tcsabina wrote: There is still a difference in the start- and end-time of the Renko bars between the strategy's calculation and the chart's value. Renko bars are price based, not time based. So, imho, the start- and end-time are not appropriate features for Renko bars. There is no standard definition of time limits of a Renko bar as well. You shouldn't rely on time features of the price aggregated bars.
|
|
|
|
 |
API Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 16 Jan, 2014, 09:31
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
tcsabina wrote: Please take a look on this. It is hard to believe that you cannot replicate this. We already did look at this, for your convenience here is our printscreen: 
Attachments: |
RenkoTest.png [72.28 KiB]
Downloaded 829 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.
|
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 16 Jan, 2014, 10:37
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
@hebasto Thanks, good point. Advise is taken!
@Support: I appreciate your help. If I may ask, is this made by running the strategy I've attached? If yes, could you help me find out why do I see a difference with the same strategy? Based on hebasto's reply this is not a critical problem, but I am still curious why do I have such difference... Also, the 2 attached strategy are using 2 different methods to subscribe to the Renko feed. Does it matter which one I use?
|
|
|
|
 |
API Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 16 Jan, 2014, 15:31
|
|
User rating: ∞
Joined: Fri 31 Aug, 2007, 09:17 Posts: 6139
|
We ran the following: public class RenkoTest implements IStrategy, IFeedListener {
@Configurable("") public IFeedDescriptor renkoFeedDescriptor = new RenkoFeedDescriptor(Instrument.EURUSD, PriceRange.valueOf(10), OfferSide.ASK);
private IConsole console; public void onStart(IContext context) throws JFException { this.console = context.getConsole(); context.setSubscribedInstruments(java.util.Collections.singleton(renkoFeedDescriptor.getInstrument()), true); context.subscribeToFeed(renkoFeedDescriptor, this); } @Override public void onFeedData(IFeedDescriptor feedDescriptor, ITimedData feedData) { console.getOut().println(feedData); }
public void onAccount(IAccount account) throws JFException {}
public void onMessage(IMessage message) throws JFException {}
public void onStop() throws JFException {}
public void onTick(Instrument instrument, ITick tick) throws JFException {}
public void onBar(Instrument instrument, Period period, IBar askBar, IBar bidBar) throws JFException {} }
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Fri 17 Jan, 2014, 00:17
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Dear Support, What I've just discovered, is that the strategy generated values are the same as yours. For example if I compare my strategy's result with the screenshot you have attached, I see the same values: 22:27:29 renko bar completed: StartTime: 2008-01-01 17:47:28.229 EndTime: 2008-01-01 18:46:55.788 O: 1.46 C: 1.46001 H: 1.461 L: 1.46 V: 27995.25 FEC: 4182
However my chart does not contain the same information about this particular candle:  You have mentioned that I have to be sure that the chart and the strategy are using the same feed. As now the strategy is generating the same data as for you, how can I be sure that my chart is using the same (proper) settings? Does it have to do anything with performance of the computer I am using? It seems that there are differences about start- and end time. As these parameters of the candles are calculated on the fly (just guessing), would a slower machine calculate different results? Or this is absolutely irrelevant? Please give me tips, what to check, as this is not the way it should be.
Attachments: |
Screenshot from 2014-01-17 00:12:50.png [144.87 KiB]
Downloaded 813 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.
|
|
|
|
|
 |
Platform Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Tue 21 Jan, 2014, 21:38
|
|
JForex Master |  |
User rating: ∞
Joined: Wed 16 Sep, 2009, 18:23 Posts: 1054 Location: Geneva, Switzerland
|
Price based periods in the charts are calculated from the interpolated 1 Minute or 1 Hour period candles at the moment due to the performance reasons. Historical tester has been run on the ticks in these tests thus making the Renko caluculate from the ticks as well. Obviously you have run the test first and then switched the chart from Bid to Ask later, forcing the chart to show the Renko calculated from the interpolated Ask candles instead of the ticks. Hence the difference in the data. API support has switched the sides before the Renko have been drawn in the test, so it had everything correct. I think I could be good to assist Hercule Poirot. Or maybe he could be my apprentice  Anyway, I hope this confusion with the Price based periods ends as soon as we offer calculating them from the ticks. Would you be ready to spend a long time in calculating the Renko from the ticks data just to be sure that you have the most precise method used? After the calculation is complete, we could cache the data locally, so the second time you open it they wouldn't be recalculated. If the answer is yes, we could get rid of the base periods as well and calculate them with the starting point set at the beginning of the ticks data. We have no other option than calculating them on your side as the custom price based periods are very many.
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 06 Feb, 2014, 13:34
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Quote: and then switched the chart from Bid to Ask later,
I think you pretty much nailed it. Quote: Would you be ready to spend a long time in calculating the Renko from the ticks data just to be sure that you have the most precise method used? After the calculation is complete, we could cache the data locally, so the second time you open it they wouldn't be recalculated. If the answer is yes, we could get rid of the base periods as well and calculate them with the starting point set at the beginning of the ticks data. We have no other option than calculating them on your side as the custom price based periods are very many.
Define 'long time'!  . Would that be an option to let the user select the calculation method for Renkos? Like an option in the platform's preferences. We can see from time to time there are some questions here on the forum about the Renko's 'behavior', so there are user who would like to have this calculation modified. But probably there are other users out there who are satisfied with the way Renko's are drawn at the moment, so probably they will be unsatisfied, as they will see this just as a slowdown. I would try to make both parties happy, and offer them the choice... And some more brainstorming on this subject: 1) If that is an option to let the user select which Renko calculation he/she want to have, and if the calculation from tick data is time (processor) consuming, let system check what hardware the platform is running on, and only make the tick data calculation available, if the CPU is powerful enough to deal with such task. 2) How about involving some extra process power to calculate Renko's from tick data? OpenCL for example.
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Thu 13 Feb, 2014, 23:25
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Dear Support,
Have you considered my reply? Are you planning to implement this other (better?) Renko chart calculation in the near future?
Please let me know.
|
|
|
|
 |
Platform Support
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Fri 14 Feb, 2014, 17:41
|
|
JForex Master |  |
User rating: ∞
Joined: Wed 16 Sep, 2009, 18:23 Posts: 1054 Location: Geneva, Switzerland
|
Returning the result for price based periods could be divided in two parts. The first one is ticks data downloading, the second is calculation. The download time would vary very much depending on the download speed. The calculation time depends on the size of the period. e.g. Renko 1 pip or 2 pips is very fast. Few seconds. Our tests showed that Renko 100 pips could take up to 1 hour depending on the start point in time (base periods or the start of the history) and the hardware.
Yes, we plan to implement several calculation methods which would be set in Preferences.
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 0
|
Posted: Mon 17 Feb, 2014, 10:29
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Sounds interesting! Any planned release dates? 
|
|
|
|
 |
tcsabina
|
Post subject: Re: mismtach between Renko bar's data on chart and within strategy |
Post rating: 1
|
Posted: Wed 19 Feb, 2014, 13:12
|
|
User rating: 164
Joined: Mon 08 Oct, 2012, 10:35 Posts: 676 Location: NetherlandsNetherlands
|
Dear Support,
May we have an update about the release date of the new price-based calculations? I think I am not the only one who is looking forward for these.
|
|
|
|
 |
|
Pages: [
1, 2
»
]
|
|
|
|
|