Line Charts

In our Python Intermediate course and our Pandas and Numpy Fundamentals course, you've mostly been manipulating and working with data that are represented as tables. Microsoft Excel, the pandas library in Python, and the CSV file format used in our datasets were all developed around this representation. 

Because a table neatly organizes values into rows and columns, we can easily look up specific values at the intersection of a row value and a column value. This makes tables great for data cleaning and some kinds of analysis. Unfortunately, it's very difficult to explore a dataset to uncover patterns when it's represented as a table, especially when that dataset contains many values. We need a different way to represent data that can help us identify patterns more easily.

In this lesson, you'll learn the basics of data visualization, a discipline that focuses on the visual representation of data. 

As humans, our brains have evolved to develop powerful visual processing capabilities. We can quickly find patterns in the visual information we encounter, which was incredibly important from a survivability standpoint. Unfortunately, when data is represented as tables of values, we can't really take advantage of our visual pattern matching capabilities. This is because our ability to quickly process symbolic values (like numbers and words) is very poor. Data visualization focuses on transforming data from table representations to visual ones, making it much easier for humans to understand.

In this first lesson, we'll use Python, pandas, and matplotlib to create line charts to analyze data from the United States Bureau of Labor Statistics to visualize unemployment data and how it changes over time.


  • Learn the importance of data visualization.
  • Learn a new data science library for data visualization.
  • Learn to create a line plot using only Python.

Mission Outline

1. Representation Of Data
2. Introduction To The Data
3. Table Representation
4. Observations From The Table Representation
5. Visual Representation
6. Introduction to Matplotlib
7. Adding Data
8. Fixing Axis Ticks
9. Adding Axis Labels And A Title
10. Next Steps
11. Takeaways


Course Info:


The median completion time for this course is 7.02 hours. View details

This course requires a basic subscription and includes four missions and one guided project.  It is the fourth course in the Data Analyst in Python path and Data Scientist in Python path.


Take a Look Inside

(function(d) { d.addEventListener("DOMContentLoaded", function() { var pathname = d.location.pathname.replace(/^[/]|[/]$/g, "").replace("/", "-"); var tags = d.getElementsByTagName("iframe"); var type = pathname.startsWith("course") ? "?course=" : pathname.startsWith("path") ? "?path=" : null; if (type) { var i; for (i = 0; i < tags.length; i++) { if (tags[i].src.indexOf("signup#iframe") !== -1) { tags[i].src = tags[i].src.replace("#iframe", "") + type + pathname + "#iframe"; } } } }, false); })(document);