All examples By author By category About

d3noob

Dynamic historical stock data with d3.js and YQL

This is a chart as used as an example to demonstrate the integration of a YQL query with d3.js and incorperating a degree of control over the query. It is described in the book D3 Tips and Tricks.

You can enter a stock in the form of a ticker symbol (YHOO = Yahoo!, MSFT = Microsoft, KO = Coca-Cola) along with a start and end date (in the format yyyy-mm-dd).

Fair Warning: There is no degree of sanitisation or validation on the inputs. The purpose is to demonstrate the YQL integration with d3.js.

Interesting note: The original version of this example used 'GOOG' as the ticker symbol, but for whatever reason it no longer appears to work.