Skip to main content
100%

MasteringD3-Resusable-ProD3js-2.3E

✓ Published0🌍 Public
JJimMaltby
Last edited Dec 9, 2021
Created on Dec 8, 2021

This example demonstrates a reusable bar code chart, a temporal visualization of daily stock-mention data for companies like AAPL and MSFT, alongside a table showing name, today’s mentions, and mentions-per-hour. It applies the ProD3.js pattern and Mike Bostock’s reusable chart principles, using d3.scaleTime for the date axis and d3.scaleOrdinal with d3.schemeCategory10 for coloring. The SVG renders animated bar lines per data row within an HTML table via a foreignObject, with D3 v5 managing scales, axes, and dispatcher events.

AI-generated description

Exploration of bar code chart example, from Chapter 2 of Mastering D3.

It is derived from Mike Bostock's Towards Reusable Charts (https://bost.ocks.org/mike/chart/) as the source of the foundational principles.

Using the ProD3 pattern (Pro D3.js Use D3.js to Create Maintainable, Modular, and Testable Charts by Marcos Iglesias https://www.apress.com/gp/book/9781484252024) as the basis for charts pattern.

MIT Licensed

Similar vizzes