dmaclean / dfs-python

Tools for DFS data collection and projection creation.
11 stars 2 forks source link

Add computation of FIP, xFIP #34

Open dmaclean opened 10 years ago

dmaclean commented 10 years ago

BBR doesn't give us FIP for pitchers, so this needs to be computed manually.

FIP = ((13*HR)+(3*(BB+HBP))-(2*K))/IP + constant
xFIP = ((13*(Flyballs * League-average HR/FB rate))+(3*(BB+HBP))-(2*K))/IP + constant

The constant is solely to bring FIP onto an ERA scale and is generally around 3.20. You can find historical FIP constant values here, or you can derive the constant by taking league-average FIP and subtracting that from league-average ERA.

dmaclean commented 10 years ago

FIP is in place but looks like it's being computed incorrectly. The function to calculate is in StatCalculator and is invoked in player_season_stats_parser.py at line 148.

dmaclean commented 10 years ago

FIP has been corrected. XFIP still needs to be created (or is FIP enough?)