View Single Post
Old 02-20-2024, 08:29 PM   #18
fhomess
Hall Of Famer
 
fhomess's Avatar
 
Join Date: Nov 2002
Posts: 3,648
Be aware that innnings in both the pitching and fielding tables is divided into IP and IPF, where IP is whole innings and IPF is fractional innings. To get an accurate IP for ERA calculation, you need to do (3*IP+IPF)/3.

Also, don't forget to consider denominators that could be 0. For example, in batting average, h/ab can result in an error if ab=0. Not going to be an issue for end of year team stats, but individual players with very little playing time might run into that.
__________________
StatsLab- PHP/MySQL based utilities for Online Leagues
Baseball Cards - Full list of known templates and documentation on card development.
fhomess is offline   Reply With Quote