Using RStudio, ggplot2 and ggrepel to visualise ball in play time at the World Cup


I am continuing to explore RStudio as a way to visualise data. I thought I would look at ball ion play time in the first 14 games played in the 2018 World Cup.
My knowledge is very basic but finding packages like ggrepel makes the learning even more enjoyable.
“ggrepel provides geoms for ggplot2 to repel overlapping text labels:

  • geom_text_repel()
  • geom_label_repel()

Text labels repel away from each other, away from data points, and away from edges of the plotting area.”
The first plot above uses this code and includes geom_text_repel() :

The second option:

Uses this code with geom_label_repel():

I am looking forward to more learning opportunities during the World Cup.

LEAVE A REPLY

Please enter your comment!
Please enter your name here