|
||||
| ||||
|
|
#1 |
|
Minors (Single A)
Join Date: May 2004
Posts: 74
|
FIP Calculated Incorrectly
It feels like the in game FIP calculations are incorrect. When we calculate FIP externally using the exported SQL data it never lines up with the in game numbers for any pitcher, ever (like it's not even close).
The formulas we are using to do the calculations for FIP and the FIP constant are as follows. FIP = ((13*HR)+(3*(BB+HBP))-(2*K))/IP + constant FIP Constant = lgERA – (((13*lgHR)+(3*(lgBB+lgHBP))-(2*lgK))/lgIP) The numbers that come out from these formulas do not seem to be the same as the ones being used in game. Is it possible to let us know the formulas being used in game so we can either change our code to match the in game formulas or can you change the in game formulas so they match the actual FIP formulas, if they are indeed incorrect? Thanks again for your time, as always it's appreciated! Last edited by Subliminal; 08-17-2020 at 03:01 PM. |
|
|
|
|
|
#2 | |
|
Banned
Join Date: Aug 2019
Location: Ban land in 3...2...
Posts: 2,943
|
Per the glossary
Quote:
Seems like you would have mentioned it, but are your calculations always off by something that would suggest it was just a difference in the constant |
|
|
|
|
|
|
#3 |
|
Minors (Single A)
Join Date: May 2004
Posts: 74
|
That is my assumption, that OOTP calculates the constant differently than the formula I provided or uses a constant that doesn't use a formula, like somewhere around 3.2ish.
|
|
|
|
|
|
#4 |
|
OOTP Developer
Join Date: Jun 2009
Location: Here and there
Posts: 16,244
|
The only thing different I see is that you need to remove intentional walks when calculating the constant, and when you list your formulas at the top you're not factoring that part in.
How far different are your calculations? |
|
|
|
|
|
#5 |
|
Minors (Single A)
Join Date: May 2004
Posts: 74
|
I'll check that out and see if the results match a little later tonight. They're off by enough but IBB might potentially be the issue. It's definitely possible that it's me and not you, but I just wanted to confirm. I'll check tonight and get back to you with some comparisons if they don't match up after I take IBB out.
|
|
|
|
|
|
#6 |
|
Minors (Single A)
Join Date: May 2004
Posts: 74
|
So upon more thought, IBB should already be factored into the BB stat so taking it out would just be redundant would it not?
Some FIP resources in which none of them show IBB being removed. https://library.fangraphs.com/pitching/fip/ https://www.baseball-reference.com/b...ndent_Pitching http://m.mlb.com/glossary/advanced-s...ndent-pitching Last edited by Subliminal; 08-18-2020 at 05:19 PM. |
|
|
|
|
|
#7 | ||
|
Banned
Join Date: Aug 2019
Location: Ban land in 3...2...
Posts: 2,943
|
Quote:
The reasoning behind taking them out is that they aren't reflective of the pitcher's skill, but the manager's decision From the MLB.com definition Quote:
|
||
|
|
|
|
|
#8 |
|
Minors (Single A)
Join Date: May 2004
Posts: 74
|
Ok so it looks like I can get my FIP calculation to match the in game calculation if I subtract IBB from BOTH formulas.
So this is what I had. FIP = ((13*HR)+(3*(BB+HBP))-(2*K))/IP + constant FIP Constant = lgERA – (((13*lgHR)+(3*(lgBB+lgHBP))-(2*lgK))/lgIP) And this is what I changed it to. FIP = ((13*HR)+(3*(BB+HBP-IBB))-(2*K))/IP + constant FIP Constant = lgERA – (((13*lgHR)+(3*(lgBB+lgHBP-IBB))-(2*lgK))/lgIP) That gives me the same FIP as shown in game. So that solves that problem then. Thanks for the help both of you, I appreciate it. I more or less wanted to know why my FIP wasn't coming out the same and it appears to be because OOTP uses a slight variation on the calculation from that of what is posted on MLB. Thanks again! |
|
|
|
![]() |
| Bookmarks |
|
|