Skip to Main Content

Guide to Data Visualization

Programming Languages

Why Should I use a Programming Language to Create Data Visualizations?

There are a number of user-friendly tools that provide a graphical interface to make data visualization faster and easier. However, all of these tools have limited capabilities. For example, many will not perform in-depth analysis or statistical tests on your data, and you may find it more efficient to use a programming language that is capable of both analysis and visualization at the same time. There are also currently no easy-to-use tools that allow for animation of data visualizations. Animation achieved in data visualization is often created either frame-by-frame or by using a programming language.

In general, programming allows for more flexibility, transparency and reproducibility of the data visualization process.

Popular Programming Languages for Creating Data Visualizations

a line plot created in R

R

R is a programming language designed for statistics and data analysis. It includes some basic visualization capabilities, but many users employ third-party created functions, or "packages", to enhance visualization options. A popular visualization package for R is ggplot2.

a network graph made with d3

JavaScript

JavaScript is a language most well known for its use in websites and web applications. Although there are many JavaScript libraries that enable data visualization, D3 is one of the most powerful and widely used. To create web visualizations with JavaScript, you will also have to be familiar with HTML and CSS, and, in the case of D3, you will need to know SVG.

a violin plot made with python

Python

Python is a popular language for both experts and first-time programmers. Although there are no visualization functions built into Python, there are many visualization libraries available. A commonly used Python visualization library is matplotlib.

Examples of Visualizations Created With Programming Languages

scatterplot made with ggplot2

A demonstration of a scatterplot created with the ggplot2 package in R.

 

bullet graph made with D3

A demonstration of a bullet diagram created with the D3 library in Javascript.

 

gantt chart made with bokeh

A demonstration of a gantt chart created with the Bokeh library in Python.