Post subject: DDSJFX-168 getBars(..., filter, from, to)
Post rating: 0
Posted: Sun 11 Apr, 2010, 20:37
User rating: 3
Joined: Wed 18 May, 2011, 16:25 Posts: 331 Location: SwitzerlandSwitzerland
could you please consider including a getBars(...) with filter and from/to times:
getBars(Instrument instrument, Period period, OfferSide side, Filter filter, long from, long to);
Thanks a lot, RR.
RoadRunner
Post subject: Re: JFOREX-1654: getBars(..., filter, from, to)
Post rating: 0
Posted: Thu 20 May, 2010, 07:11
User rating: 3
Joined: Wed 18 May, 2011, 16:25 Posts: 331 Location: SwitzerlandSwitzerland
Hi,
this topic has been moved to finished issues. Will it get included in one of the next versions? At the moment in order to get filtered bars within a specified period in time, one has to work with the start time of the end bar and the estimated number of bars for a shift back in time and then loop through the return list to get the bar that is >= the start time, one is looking for. It would be very beneficial, if you could include a timefrom/timeto version of a filtered getBars.
Could you please let me know your plans? Thanks, RR.
[brainstom]
Post subject: gettimeForNBarsBack() / getTimeForNBarsForward()
these 2 methods should also accept a Filter specifier. Otherwise one can not fetch the appropriate number of (filtered) bars, given a start time.
Example: I need to fetch all bars between a certain point past in time (an order open for example) and now. I want to filter out all flats. getBars() with filter specifier requires a number of candles, not "from" and "to" time specifiers. Since the bars are filtered, I can not know beforehand how many candles there are effectively between two points in time.
Alternatively to gettimeForNBarsBack() / getTimeForNBarsForward() also taking a filter specifier; a version of getBars() taking filter and "from" - "to" time would allow to do what is needed here.