block by d3noob 1004aeffa0dad7b1f9e8b45d28bbeb94

Multi-line graph 1 with v6: Lines

Full Screen

This is an example in the book D3 Tips and Tricks v6. The stock data was sourced from Mike Bostock’s small multiples example.

It is the first graph in a series that is building a multi-line graph that incorperates an automatically developed legend and a system that can toggle the lines off and on as desired.

This version is demonstrating the use of the d3.group function to group the data to allow the different lines to be drawn.

The graph should be taken in context with the text of the book which can be downloaded for free from Leanpub.

index.html

stocks.csv