Hello Salcucco. Great question! Unfortunately, not a easy answer. First, there is no "standard" barrel length. The famous German K98 Mauser of WWII famewas a fairly short barrel carbine. The US 03A3 sniper rifle had a 23? or so inch barrel. David Tubb wins the national match with a 27 inch barrel with a one in 7 1/2 twist with a 6mm caliber. Did I mention "twist?" Yep, the twist of the land and groves is really, IMHO, more important than the barrel length. For instance if your barrel is 20 inches long and the lands and groves make 2 complete revolutions....you have a 1 in 10 twist. Some barrels are extremely accurate with a 140gr bullet and totally spastic with a 160gr bullet!
Well, I'm confused so you should be too. I would do this. Pick your caliber based on what you want to hunt or plink then do some research on that combination and come back to the forum. There is a brain trust here that will maximize the barrel length from there.

Regards, Rick.