Skip to content

Pull out customized frequency from trading-IG historical data #279

Answered by starsnpixel
kiann00 asked this question in Q&A
Discussion options

You must be logged in to vote

I'm not sure if I understand your question correctly. If you check out the function definition in rest.py, you'll find

:param resolution: (str, optional) timescale resolution. Expected values
            are 1Min, 2Min, 3Min, 5Min, 10Min, 15Min, 30Min, 1H, 2H, 3H, 4H, D,
            W, M. Default is 1Min

So if you only want the 5min timeframe, just call it by ig_service.fetch_historical_prices_by_epic_and_num_points(epic, '5Min', ...) it should do exactly what you're looking for.

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@kiann00
Comment options

@oliverpolden
Comment options

@kiann00
Comment options

@starsnpixel
Comment options

@starsnpixel
Comment options

Answer selected by kiann00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants