For example, of the Roman Empire's total life, how many years of peace versus war in some form did it have?
So the question we really need to tackle is: What do you mean by "been at war"? The United States has not legally been at war since 1945, which means weve had nearly 70 years of uninterrupted peace since the end of World War Two. Infact, in its history the United States has only issued 5 declarations of war, so (again) legally, weve only been to war 5 times. But that doesnt count that thing in Vietnam, the thing in Korea, or either thing in Iraq. But what are those? Youd likely suggest that they were undeclared wars, but they were still wars. Id agree with that, but it raises a stickier question. We could all accept that conflicts like Vietnam, Korea, and Iraq are wars, but what else? Is the 1989 invasion of Panama a war? What about the intervention in Afghanistan? What about Operation Gothic Serpent, which spawned the Battle of Mogadishu and the famous Black Hawk Down incident? How small a conflict can I find that still constitutes a war? What about during Hurricane Katrina, when there were reports of sniper fire against National Gaurd Units? And how do we classify the Civil War? Surely its a war, but the United States never recognized the CSA. Then theres the KKK and its guerilla war against federal troops, whats that? And what of the Cold War, and our (continued) impending deaths in a great nuclear holocaust?
So, there is a lot going on in this question, including producing a workable definition of what a war is, exactly. To then compare that information with another country, youd have to create a robust definition which fits both nations peculiar histories, no small feat! And a country like Rome is doubly difficult, with so much of its history shrouded in the past. We really have very few sources which detail the history of Rome, and even fewer ever discuss the micro-wars which were fighting over. So in that case, itd be next to impossible to create a definition of war that would work between the two nations, and that would include every "relevant" American conflict, and that would produce useful results. Its like comparing apples to onions, you could call both "food", and both "round", but they have very little else in common.
And then we have to figure out what is an American war? What about the Pequot war of 1634, fought between Massachusetts Indians and colonists of Massachusetts Bay.
Thats maybe not the answer you were looking for, was it? Well, heres as close to an answer Ill probably give: The United States has been at war for virtually all meaningful periods of time throughout its history. Between the decades long Indian Wars, a conflict which lasted most of the 18th and 19th centuries, the American interventions in Latin America, the European Civil War, the Cold War, and the Post-Cold War, you can always find some kind of conflict, large or small. Some American soldier, somewhere, has always been in a combat zone.