Overview of Chart Types and Examples

Understand different types of charts and when to use them

Quorum studio provides seven different types of charts: Bar Charts, Pie Charts, Box Plots, Histograms, Violin Plots, Line Charts, and Scatter Plots to use to represent our data. Learning a new programming language could be daunting for people with no experience of coding, but we are here to ease the process with the following tutorial. For this chart, we will be making a simple bar chart. We can disregard the contents of the chart for now as we will be later going in-depth about the appropriate use of charts. The code we can use for our first chart is below:

Learning Objectives

In this tutorial, students will learn:

  1. Students will learn why it is important to have data visualizations in the form of accessible charts
  2. Students will learn the necessary features on making good charts
  3. Students will learn about various types of charts and when to use them

Introduction to Charts (10 Minutes)

When presenting data to others, our job is to translate our findings into a representation that makes the data easier to grasp. One common approach to do this is to present charts, which contain a visual component and can also be accessible with some care. Presenting our data as a chart allows us to quickly explain our analysis and draw conclusions from datasets we have collected without needing to present complex academic statistical analysis. In a sense, charts let us get the gist of what our data is telling us, supposing the chart is fairly presented.

Let us imagine what it would be like if we had no way to present our data beyond the numbers themselves. We would have millions of values to explain and we would not be able to showcase trends easily that make sense to others. Charts can help us present our information better and help us remember our data versus examining a dataset. We can discuss how data charts are represented all throughout education and industries, providing examples of each.

How Charts Relate to Data Science (5 Minutes)

Charts are important outside of academic settings, where many data scientists use data visualization to represent the information found on datasets. Since data in real life often involves large amounts of data, it's more important than ever that we can actually condense that information into something more meaningful.

Showing the importance of graphical charts in data science allows us to identify and understand massive amounts of information. In Quorum, we have seven different chart types to represent data: Bar Charts, Pie Charts, Box Plots, Histograms, Violin Plots, Line Charts, and Scatter Plots. We will be learning how to create these charts in the upcoming lessons.

Making Our First Chart in Quorum (20 Minutes)

use Libraries.Compute.Statistics.DataFrame
use Libraries.Interface.Controls.Charts.BarChart
use Libraries.Compute.Statistics.Columns.TextColumn
use Libraries.Compute.Statistics.Columns.NumberColumn

/*
    This is an example of how to read in data with data frames
*/

// create frame component
DataFrame frame

// read in data from dog csv
frame:Load("data/Dogs.csv")

// pull out specific columns from csv that we are comparing
frame:AddSelectedFactors("Breed Group") // this will pull out the breed group from table and label on the x axis
frame:AddSelectedColumns("Maximum Weight") // this will pull out the max weight from table and label on the y axis
frame:AddSelectedColumns("Minimum Weight")
frame:AddSelectedColumns("Maximum Height")
frame:AddSelectedColumns("Minimum Height")

// using the data frame, format data by creating a bar chart component
BarChart chart = frame:BarChart()

chart:ShowLegend(false)
chart:SetTitle("Example of displaying Dogs.csv")

// display chart on window
chart:Display(100,100)

While we may not fully comprehend what is going on in this program, we can see that whether we are using Quorum Studio or the online editor, a chart pops up! We will be going over the syntax of the code in a future lesson.

Chart Types (15 Minutes)

Different charts are used to convey different types of information, meaning, there is no single chart we can use to represent all data. For example, say we wanted to represent the amount of people who eat breakfast- we'd probably want to use something like a pie chart, so that the main focus is on the contrasting percentages. However, if we wanted to represent something like the cost of living in Washington DC in the past 20 years, we might instead want to use a line graph. That way people would be able to follow the costs changing as the years change. There are some types of data that we might be able to represent in multiple types of charts. For example, a class survey based on favorite ice cream flavors could use either a bar chart or a pie chart.

We can discuss the seven different types of charts in Quorum and when to use them appropriately. The following table shows a chart type and its usage.

Chart Types
Chart Type When to use this chart
Bar ChartTo compare categorical data or summary statistics from 1 or more groups
Pie ChartTo depict a single variable or multiple variables with respect to change over time
Line ChartTo portray sampling distribution with continuous independent variables
HistogramTo show the distribution of data of 1 or more groups
Scatter PlotTo show frequencies or percentages
Box PlotTo determine if two variables have a relationship or correlation
Violin PlotTo visualize peaks and distributions in numerical data

Making 'Good Charts' (10 Minutes)

While we are aware of how to make a basic chart and its usage, we still want to have meaningful content that would not confuse others. Many times in academic papers, graphs and other visualizations are confusing because the data represented cannot be understood from solely the chart. It is important that when making a chart, context should be at the forefront while presenting our data. We can reference this tutorial of how to construct 'good charts' to make a clear and concise chart.

Relevant Common Core Standards

We use the following for common core standards in relation to histograms and measurements of distribution.

Common Core Standards for Math

CCSS.MATH.CONTENT.HSS.ID.B.6.A: Represent data with plots on the real number line (dot plots, histograms, and box plots).

CCSS.MATH.CONTENT.HSS.ID.B.6.A: Represent data on two quantitative variables on a scatter plot, and describe how the variables are related.

Next Tutorial

In the next tutorial, we will discuss Bar Charts, which describes Learn how to make and customize bar charts..