README.md

olympicmarathon

Lifecycle:
experimental CRAN
status R-CMD-check

olympicmarathon is an R package that contains historic data about Olympic marathon competitors and functionality to work with the data. Previously, data about Olympic marathons has been rather sparse, and official data is usually published in PDF form which creates barriers to performing analysis on it. This package aims to facilitate the viewing and analysis of the data by compiling it into one place for easy access and creating functionality for painless exploration. The data is compiled from the World Athletics Website and OlympianDatabase.com.

Installation

You can install the current version of olympicmarathon from GitHub using the following code:

devtools::install_packages("mflesaker/olympicmarathon")

Load

Load the package with the following code:

library(olympicmarathon)

Available Tables

Example: Basic Data Extraction

## Generate the winner of the 2020 Olympic Women's Marathon

olympic_marathon %>%
  dplyr::filter(gender == "F") %>%
  dplyr::filter(year == 2020) %>%
  dplyr::filter(rank == 1) %>%
  dplyr::pull(name)
#> [1] "Peres Jepchirchir"

Example: Visualize Data

## Show all finishing times 1984-2020

times_over_time()

Contributors



mflesaker/olympicmarathon documentation built on May 4, 2022, 5:36 p.m.