The goal of this chapter is to get you up and running with D3.js. You will learn how to use the most important modules and walk through a collection of examples that demonstrate how D3 maps data to visualizations. We will start by binding data to HTML <div> elements and paragraphs to create a simple horizontal bar chart, complete with labels, a color scheme, and dynamic scaling, and then bind the same data to SVG, which offers many more possibilities. You will learn how to add gradients, configure animated transitions, and handle events in this chart. Before the end of the chapter, you will even draw a world map using D3. After finishing this chapter, you should have a general working knowledge of D3 that will enable you to create simple charts with your own data.
To follow the examples in this chapter, you should set up a development environment with D3, which...