cuemacro / findatapy

Python library to download market data via Bloomberg, Eikon, Quandl, Yahoo etc.
Apache License 2.0
1.7k stars 206 forks source link

Download ohlc data from dukascopy #30

Closed alphajoza closed 4 years ago

alphajoza commented 4 years ago

Hi. Downloading ohlc data from dukascopy using the code bellow gives error;

from findatapy.market import Market, MarketDataRequest, MarketDataGenerator

market = Market(market_data_generator=MarketDataGenerator())

md_request = MarketDataRequest(start_date='14 Jun 2016', finish_date='15 Jun 2016',
                                   category='fx', fields=['Open','High','Low','Close','Volume'], freq='1m', 
                                   data_source='dukascopy', tickers=['EURUSD'])

df = market.fetch_market(md_request)
print(df.tail(n=10))