Learn R Programming

baseballr (version 0.2.0)

pitcher_boxscore: Retrieve pitcher boxscore data for a single game played

Description

This function allows a user to retrieve a boxscore of pitcher statistics for any game played in the PITCHf/x era (2008-current). The function takes a boxscore.xml url as it's only argument and returns boxscore data for both the home and away pitchers.

Usage

pitcher_boxscore(x)

Arguments

x
A boxscore.xml url for a given game from the MLBAM GameDay app data.

Examples

Run this code
pitcher_boxscore("http://gd2.mlb.com/components/game/mlb/year_2016/month_05/day_21/gid_2016_05_21_milmlb_nynmlb_1/boxscore.xml")

Run the code above in your browser using DataLab