curriculum/challenges/english/blocks/lecture-introduction-to-data-visualization/695b9093a0c45b36932dcbcb.md
In the prior lessons, you were introduced to data visualization which is the process of creating clear, visual formats to represent complex data. In this lesson, you will learn about the D3 library.
The D3 library is a free and open source library you can use to create compelling and effective data visualizations in JavaScript.
The name D3 is an abbreviation for data-driven documents, referring to how it dynamically binds data to elements in the Document Object Model (DOM). This library is flexible and works naturally with the web. Instead of having to learn a whole new graphical representation, you can build data visualizations with svg and canvas elements.
For example, if you want to create a bar chart using D3, you can do the following all in one JS file:
Declare variables representing the chart dimensions and margins
Declare the horizontal position scale
Declare the vertical position scale
Create the SVG container with the bars and labels
So what are some other reasons to learn D3 over other visualization tools like Chart.js, Plotly, or Tableau?
Unlike other tools, D3 provides you with a lot of low-level control where you can build customizable and interactive visualizations with just vanilla HTML, CSS, and JavaScript. Plus, the library is in JavaScript, so you don't need to worry about learning a whole new language.
In upcoming workshops and labs, you will learn the fundamentals of the D3 library, like selections, shapes, and scales. You will learn these key concepts by building scatterplot graphs, bar charts, dashboard apps, and more.
What is the D3 library?
A free and open source library for creating compilers.
Refer back to the beginning of the lesson for the answer.
A free and open source library for creating interactive forms and tables.
Refer back to the beginning of the lesson for the answer.
A free and open source library for creating data visualizations in JavaScript.
A free and open source library for creating microservices.
Refer back to the beginning of the lesson for the answer.
3
What is one advantage to using D3 over another tool like Chart.js or Tableau?
D3 automatically generates all chart types with minimal configuration, similar to drag-and-drop tools.
Think about the level of control D3 provides you.
D3 provides you with low-level control so you can build customizable and interactive visualizations.
D3 includes a built-in GUI (graphical user interface) for creating dashboards without writing code.
Think about the level of control D3 provides you.
D3 uses a completely new programming language designed for data visualization.
Think about the level of control D3 provides you.
2
What is a type of project you will build in this data visualization module?
e-commerce site
Refer to the end of the lesson for the answer.
express server
Refer to the end of the lesson for the answer.
discord bot
Refer to the end of the lesson for the answer.
scatterplot graph
4