era: Earned-Run Average (ERA)

Description Usage Arguments Details Value Note Author(s) References See Also Examples

Description

ERA is a basic metric used to describe a pitchers ability to prevent runs.

Usage

1
era(er, ip)

Arguments

er

Earned Runs

ip

Innings Pitched

Details

ERA is not a perfect indicator of pitcher skill. It is highly defense dependent.

Value

Returns a numerical value equal to (9*er)/ip

Note

Innings Pitched (IP) is commonly reported with .1 indicating 1/3 of an inning and .2 indicating 2/3 of an inning. In order for this function to be accurate, please change the decimal to .333 for 1/3 of an inning and .666 for 2/3 of an inning.

Author(s)

Fernando Crema, Peter Xenopoulos

References

http://www.fangraphs.com/library/pitching/era/

See Also

whip,fip,xfip

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Let's calculate Clayton Kershaw's ERA for the 2014 Season
## He had 39 ER's and 198.333 IP
## We should get an ERA = to 1.77
era(39,198.333)

## The function is currently defined as
function (er, ip) 
{
    era <- (9 * er)/ip
    return(era)
  }

peterxeno/sabermetrics-package documentation built on May 25, 2019, 2:10 a.m.