Dukascopy
 
 
Wiki JStore Search Login

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.

How to go about retrieving a list of x 1h bars, including the currently forming 1h bar?
 Post subject: How to go about retrieving a list of x 1h bars, including the currently forming 1h bar? Post rating: 0   New post Posted: Fri 21 Nov, 2014, 09:43 

User rating: 0
Joined: Fri 17 May, 2013, 06:58
Posts: 76
Location: SwedenSweden
Hi,

How to go about retrieving a list of x 1h bars, including the currently forming 1h bar?

I guess I could loop a shift value from 0 to x-1 for:

history.getBar(Instrument.EURUSD, Period.ONE_HOUR, OfferSide.BID, shift);

However, I do not think that this would be very efficient.

Thanks.

Kind Regards,
Henrik


 
 Post subject: Re: How to go about retrieving a list of x 1h bars, including the currently forming 1h bar? Post rating: 0   New post Posted: Fri 21 Nov, 2014, 13:23 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Take a look at this wiki section: https://www.dukascopy.com/wiki/#History_bars


 

Jump to:  

cron
  © 1998-2024 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com