Click the Original, Code and Reconstruction tabs to read about the issues and how they were fixed.
Objective The original Data visualization was intended to show viewers(football fans)how many goals have been scored at each stadium(12) in the 2018 FIFA World cup held in Russia. This visualization only shows goals scored till 2018 June 30th.
The visualisation chosen had the following three main issues:
Colour issue: There is no point in adding different colours to this pie chart sections as they all show the same stat (number of goals scored) and there are similar colours for some of the stadiums which makes it even more difficult to understand the pie chart.
When using pie chart, Data should be represented as a percentage and it should add up to 100 per cent. This visualization fails at that. The title is misleading it tells us that it shows goals scored in FIFA World Cup 2018 but it only shows goals scored till 30 June 2018 but the competition ended on 16 July 2018.
When representing a stat it should be in an order (sorted) and it’s hard to differentiate between stadiums as both saint Petersburg stadium with 10 goals scored and Rostov Arena with 9 goals scored look the same. In the above visualization, some sections are represented by stadium names and some by city names which makes it hard to understand the visualization.
A bar chart can be used to address these issues.
Reference
The following code was used to fix the issues identified in the original.
library(dplyr)
library(ggplot2)
library(readr)
Stadium = c("Central", "Mordovia", "Vologograd", "Kaliningrad", "Cosmos", "Krestovsky", "Rostov", "Otkritie", "Luzhniki", "Kazan", "Nizhny Novgorod", "Fisht")
Goals = c(9, 9, 9, 10, 11, 14, 14, 16, 18, 19, 19, 21)
Worldcup <- data.frame(Stadium,Goals)
p1 <- Worldcup
p1 %>%
ggplot(aes(reorder(Stadium,Goals),Goals)) +
geom_col() +
geom_bar(stat="identity", fill="brown4")+
geom_text(aes(label=Goals), vjust=-0.5, size=3)+
theme_minimal() +
theme(axis.text.x = element_text(angle = 50, hjust = 1),
plot.title = element_text(size = 15,hjust = 1)) +
labs(title = "FIFA World Cup 2018 - Goals per stadium",
x = "Stadium",
y = "Goals Scored")
Data Reference
FIFA World Cup Staticts Section. (2018). wikipedia. Retrieved May 2, 2022, from Wikipedia website: https://en.wikipedia.org/wiki/2018_FIFA_World_Cup_statistics
ggplot guide section.(2022).Retrieved May 2, 2022, from sthda website: http://www.sthda.com/english/wiki/ggplot2-barplots-quick-start-guide-r-software-and-data-visualization
The following plot fixes the main issues in the original.