Graph and table with tricks in v6
✓ Published0🌍 Public
Dd3noob
Last edited Sep 15, 2020
Created on Sep 15, 2020
A line chart plots stock closing prices over time for Apple (AAPL) in April-May 2012. A sorted HTML table appears below the chart with the date, close, open, and computed difference columns. The example uses D3 v6 with SVG, `d3.csv`, `d3.timeParse`, `d3.scaleTime`, `d3.scaleLinear`, and `d3.line` to render the graph, and builds the table with D3's selection and data-join methods. The table's rows are sorted by closing price using `d3.descending`, and headers are capitalized via text transformation.
AI-generated descriptionThis is a simple graph demonstrating the addition of a table with several 'tricks' and a graph (open in full screen to see the table).
This graph is part of the code samples for the update to the book D3 Tips and Tricks to version 6 of d3.js.
mit Licensed