Published
Edited
Mar 17, 2018
Insert cell
Insert cell
dates = ["2018-01-01", "2018-02-01", "2018-03-01"]
Insert cell
Insert cell
`https://api.fixer.io/${dates[ 0 ]}?base=GBP`
Insert cell
Insert cell
urls = dates.map( d => `https://api.fixer.io/${d}?base=GBP` )
Insert cell
Insert cell
Insert cell
promises = urls.map( url => d3.json( url ) )
Insert cell
Insert cell
rates = Promise.all( promises )
Insert cell
Insert cell
onelineRates = Promise.all( dates.map( date => d3.json( `https://api.fixer.io/${date}?base=GBP` ) ) )
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more