Batting average is hits divided by at bats (hits + outs + reached on error).
ERA is earned runs divided by innings pitched, then multiplied by nine (in other words, the average number of earned runs given up over nine innings).
For more info: Baseball-almanac
reaching on error counts as an out so. Remember BB(walks), sac bunts, sac flies and HPB do not count as plate appearences.
Baseball is very much math related. All of the player stats are mathematical. Managers use this math to decide batting orders, pitching rotations, when to substitute, bunt, steal, intentionally walk, etc.
Doctors can use percentages in a great many number of ways. Doctors can use percentages to calculate the probability for having a certain disease.
The team's runners in scoring position stats this season show that they have a batting average of .275 and an on-base percentage of .350 in those situations.
Hank Aaron and Babe Ruth
In 1883, Art Benedict played in 3 games, all for the Philadelphia Quakers, and batting in all of them. He had 15 at bats, getting 4 hits, for a .267 batting average, with 4 runs batted in. He was walked 0 times. He struck out 4 times. He hit 1 double, 0 triples, and 0 home runs.
In 1882, Tug Arundel played in 1 games, batting in all of them. He had 5 at bats, getting 0 hits, for a .000 batting average, with runs batted in. He was walked 0 times. He struck out times.
In 1884, Frank Bahret played in 2 games, batting in all of them. He had 8 at bats, getting 0 hits, for a .000 batting average, with runs batted in. He was walked 0 times. He struck out times.
In 1892, Collins played in 1 games, batting in all of them. He had 2 at bats, getting 0 hits, for a .000 batting average, with 0 runs batted in. He was walked 0 times. He struck out 0 times.
In 1882, Morrie Critchley played in 1 games, batting in all of them. He had 5 at bats, getting 0 hits, for a .000 batting average, with runs batted in. He was walked 0 times. He struck out times.
In 1999, Will Cunnane played in 24 games, batting in 22 of them. He had 3 at bats, getting 0 hits, for a .000 batting average, with 0 runs batted in. He was walked 0 times. He struck out 1 times.
In 2001, Will Cunnane played in 32 games, batting in 31 of them. He had 7 at bats, getting 0 hits, for a .000 batting average, with 0 runs batted in. He was walked 0 times. He struck out 1 times.
In 1884, Tom Daly played in 2 games, batting in all of them. He had 8 at bats, getting 0 hits, for a .000 batting average, with runs batted in. He was walked 0 times. He struck out times.