numvana

Baseball Batting Stats Calculator (AVG, OBP, SLG, OPS)

Calculate batting average, on-base percentage, slugging percentage, and OPS from a batter's raw counting stats.

Batting average (AVG)
0.3
Total bases (TB)
250
Slugging percentage (SLG)
0.5
On-base percentage (OBP)
0.366
On-base plus slugging (OPS)
0.866

How it works

Batting average is the simplest rate stat, hits per at-bat: AVG = H ÷ AB. Slugging percentage weights hits by how many bases they're worth instead of counting every hit the same: total bases TB = singles + 2×doubles + 3×triples + 4×home runs (where singles = H − doubles − triples − home runs), then SLG = TB ÷ AB — a player who hits only home runs can slug well above 1.000, since a home run is worth four bases from a single at-bat.

On-base percentage answers a different question than batting average — how often a player reaches base at all, not just by a hit: OBP = (H + BB + HBP) ÷ (AB + BB + HBP + SF), adding walks and hit-by-pitches to both the 'reached base' count and the plate-appearance denominator (sacrifice bunts are excluded from both by convention, and aren't tracked here). OPS combines the two into one figure, simply OBP + SLG, giving a quick read on both how often a player reaches base and how much damage they do once they get a hit.

FAQ

Why does OPS just add OBP and SLG instead of weighting them?

That's exactly the criticism sabermetricians make of plain OPS — the two rates aren't on the same scale (OBP has a narrower typical range than SLG), so a point of OBP and a point of SLG don't contribute equally to actually scoring runs. More refined stats like wOBA weight the components differently, but OPS remains a widely used quick estimate precisely because it's simple to compute from a boxscore, which is what this calculator reproduces.

Why isn't sacrifice bunts (SH) part of the on-base percentage formula?

By long-standing scoring convention, a sacrifice bunt is treated as a deliberate out that advances a runner rather than a batting outcome that should count against a hitter's rate stats, so it's excluded from both the numerator and denominator of OBP. A sacrifice fly (SF) is treated differently — it's included in the denominator, since it was still a batted ball the hitter is credited with putting in play.

Related calculators