Click the Original, Code and Reconstruction tabs to read about the issues and how they were fixed.

Original


Source: HowMuch.net, a financial literacy website (26 Oct 2016).


Objective

  • The main objective of the original data visualization is to demonstrate the GDP of the top 10 countries and their respective Per capita income.

  • Here the United States is considered as Sun and nine planets(Pluto is also included) represent the remaining countries from the top 10. Size of the Sun and planets represent the GDP value in Billions USD and distance from the United States to other countries expresses the difference in Percapita income with respect to the U.S.

  • The target audiences are Economists and general audience who are looking for information about GDP and Percapita Income of Countries with visualization for comparison.

The visualisation chosen had the following three main issues:

  • Visual bombardment: the data visualization distracts the audience with a 3D image that has Sun and planets and a glitter backdrop which makes it hard for the audience to concentrate on the data values.

  • Size as Quantity and Distance used to express the difference: Using the size of the planet and Sun for the GDP values can easily deceive the General audience. For instance, the size of the United States(Sun) and China(Uranus) in the visualization is almost the same but has a GDP difference of USD 7,175 Billion. And using the distance between Sun and Planets to show the Percapita difference between the United States and other countries is deceptive, as Brazil and India appear to be of the same distance from the U.S, whose Percapita income is USD 7,447 and USD 1,747 respectively.

  • Ignoring Conventions : The visualisation does not have any X or Y-axis. When these conventions are ignored,it is confusing for the audience and they need more time to understand the visualisation.

Reference

Code

The following code was used to fix the issues identified in the original.

library(ggplot2)
library(readr)
library(magrittr)
library(tidyverse)
percapita <- read_csv("Percapita.csv")
gdp <- read_csv("GDP.csv")
# To select Top 10 Countries based on their GDP
gdp_top10_country <- gdp %>% arrange(desc(`2016`))
gdp_top10_country <- gdp_top10_country[1:10, c("Country", "2016")]

#To select top 10 Countries based on thier GDP from Percapita Data Frame
top10GDPCountries <-
  c(
    'United States',
    'China',
    'Japan',
    'Germany',
    'United Kingdom',
    'France',
    'India',
    'Italy',
    'Brazil',
    'Canada'
  )
Percapita_Of_Top10_GDP_Countries <-
  percapita %>% filter(Country %in%  top10GDPCountries)
Percapita_Of_Top10_GDP_Countries <-
  Percapita_Of_Top10_GDP_Countries[, c("Country", "2016")]

#To display bars in the order of GDP
Percapita_Of_Top10_GDP_Countries$Country <-
  Percapita_Of_Top10_GDP_Countries$Country %>% factor(
    levels = c(
      'United States',
      'China',
      'Japan',
      'Germany',
      'United Kingdom',
      'France',
      'India',
      'Italy',
      'Brazil',
      'Canada'
    ),
    ordered = TRUE
  )
#For Countries against GDP
p1 <- ggplot(gdp_top10_country, aes(x = reorder(Country,-`2016`) , y = `2016`))
p1 <- p1 + geom_bar(stat = "identity", color = '#35794b', fill = "#A6CE95") +
  labs(title = "GDP of Top 10 Countries in 2016",
       x = "Country",
       y = "GDP in Billions USD") +
  scale_x_discrete(labels = c("United Kingdom" = "United\nKingdom", "United States" = "United\nStates")) +
  scale_y_continuous(breaks = seq(0, 18000, by = 4000)) + geom_text(aes(label = `2016`), 
                              vjust = -0.3, size = 3.5) +
  theme_bw() + theme(
    plot.title = element_text(hjust = 0.5, face = "bold"),
    axis.text.x = element_text(size = 11),
    axis.text.y = element_text(size = 11),
    axis.title = element_text(face = "bold")
  )
#For Countries against Percapita Income
p2 <- ggplot(Percapita_Of_Top10_GDP_Countries, aes(x = Country, y = `2016`))
p2 <- p2 + geom_bar(stat = "identity", color = '#35794b', fill = "#A6CE95") +
  labs(title = "Percapita of Top 10 GDP Countries in 2016",
       x = "Country",
       y = "Percapita in USD") +
  scale_x_discrete(labels = c("United Kingdom" = "United\nKingdom", "United States" = "United\nStates")) +
  scale_y_continuous(breaks = seq(0, 60000, by = 10000)) + geom_text(aes(label = `2016`), 
                              vjust = -0.3, size = 3.5) +
  theme_bw() + theme(
    plot.title = element_text(hjust = 0.5, face = "bold"),
    axis.text.x = element_text(size = 11),
    axis.text.y = element_text(size = 11),
    axis.title = element_text(face = "bold")
  )

Data Reference

Reconstruction

Two bar graphs are used to represent the GDP and Percapita Income of Top 10 countries based on their GDP as sclaes for these values are different, GDP is in Billions USD and Percapita income is in USD.
The following plot fixes the main issues in the original.