Skip to content

Grabs candle data for FX pairs from Oanda servers.

Notifications You must be signed in to change notification settings

bgwrites/PyCandleData

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

PyCandleData

This is script scrapes candle data for FX pairs from Oanda servers.

Getting started

DISCLAIMER! Forex trading carries a heavy amount of risk. Any and everything outlined in this code is for educational purposes only. I am not responsible for any of your losses or any hardships you may face as a result of using this code. Again, this is meant to be used ONLY for educational purposes.

You will need to install oandapyV20. If you do not know how to setup a python environment, I reccomend using Anaconda or learning how to use virtualenv. There are numerous tutorials online for this.

Heads up, Oanda only allows a maximum of 4000 candles returned. If you require more, you will need to alter this script or run it multiple times with changes to the dates.

  1. Create a demo account with Oanda and obtain an api key.
  2. Place your api key in the script under "access_token".
  3. Adjust the script best on the type of data you would like. Ex.(Granularity, pair, timezone). Checkout Oanda's API endpoints for the type of data you want to grab. This should be pretty self-explanatory from the script. http://developer.oanda.com/rest-live-v20/introduction/
  4. Point your terminal to the project directory and run getCandleData.py in terminal with:

user$: python getCandleData.py

Data will be stored in a folder titled "dataStore" in whatever directory you placed the script.

About

Grabs candle data for FX pairs from Oanda servers.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages