knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)
library(eplR)

Data that comes with the package

The eplR package comes with a built in dataset for 17 seasons of English Premier League (soccer) games. They are from 2002/2003 to 2018/2019. To call on the dataset just use call eplData. The format of eplData is a list of dataframes so to get the dataframe for 2009/2010 season use the following code:

# Get Data for season 2009/2010
head(eplData[[8]])

Specific Data Query

For an easier version to query the data. You can use the getData() function. This function allows you to specify the season, whether you want additional betting information and whether you only want to have season data for a specific team.

# Query Data
head(getData(1617, bet = FALSE, team = "Liverpool"))

Referee Data

For users who are interested in analysing the season statistics for referees, you can use the referee() function, which will output a specialized query for referee-related information.

# Get Referee stats for 2013-2014 season
head(referee(1314))

Team Data

To get summary statistics for a particular team during a particular season, use the teamData() function.

teamData(1112, "Wolves")

Team Performance

To visualize the performance of a team over the course of a particular season, use the teamPerformance() function.

# Look at the performance of Man City and Man United in the 2018-2019 season
teamPerformance(1819, "Man City")
teamPerformance(1819, "Man United")


gl2668/eplR documentation built on Dec. 18, 2019, 2:34 a.m.