footballR is an R package that calls various free football (soccer) APIs.
There's quite a few good free resources for football data out there. Some detailed historical data taken is available from the openfootball and the jokecamp github pages. You can read a detailed review of all football data sources and API services here.
Install from GitLab
# install.packages("devtools") devtools::install_git("https://gitlab.com/dashee87/footballR.git") library("footballR")
You can install from GitHub (identical mirror of GitLab)
# install.packages("devtools") devtools::install_github("dashee87/footballR") library("footballR")
Alternatively, you can copy the R files onto your computer and run them all locally (only if the other approaches fail for some reason).
The package relies on httr and jsonlite. The former handles calls to the API, while the latter converts the call output from JSON to data frames. These should be installed automatically with the package.
A short tutorial on how to use the football-data.org API is available here.
This package is under active development and is subject to regular updates.
Currently, the package only supports calls to the football-data.org API.
Please let me know if something's not working.
- Sports Open Data API
- Possibly web scraping (liveScores, soccerway, etc)
- Shiny Apps
- Online football data resources
- More to come
footballR package is provided with absolutely no warranty.