Pythagorean Expectation

Share:

Description

Pythagorean expectation portrays what a team's winning percentage "should" be given it's runs scored and allowed.

Usage

1
pyth(rs, ra, alpha = 2)

Arguments

rs

Runs Scored

ra

Runs Allowed

alpha

Exponent to use

Details

2 and 1.83 are the most common exponents used. 1.83 is the exponent baseball-reference uses in its calculations.

Value

Returns a value equal to (rs^alpha)/(rs^alpha + ra^alpha)

Note

Pythagorean expectation can be used in a multitude of sports like basketball and football

Author(s)

Peter Xenopoulos

References

http://www.fangraphs.com/library/principles/expected-wins-and-losses/ https://en.wikipedia.org/wiki/Pythagorean_expectation

See Also

log5

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Let's calculate the Angels 2014 Pythagorean Expectation
## The Angels had 773 Runs Scored and 630 Runs Allowed
## We should get an output close to .600
pyth(773,630,2)

## The function is currently defined as
function (rs, ra, alpha = 2) 
{
    pyth <- (rs^alpha)/(rs^alpha + ra^alpha)
    return(pyth)
  }