Geometric Mean: Definition, Formula and Examples

By Dr. Zubair Khalid, DVM, MS, PhD ·

Geometric Mean: Definition, Formula and Examples

The geometric mean is the average you use when values multiply together instead of adding. You find it by multiplying all the values and taking the nth root of the product, where n is the number of values. It is the right average for growth rates, ratios, percentages and any quantity that compounds over time.

Quick Answer

  • The geometric mean of $n$ positive numbers is the $n$th root of their product: $\text{GM} = (x_1 \times x_2 \times \dots \times x_n)^{1/n}$ [1].
  • It answers the question "if all the quantities had the same value, what would that value have to be in order to achieve the same product?" [2].
  • It is always less than or equal to the arithmetic mean, and equal only when every value is identical [3][1].
  • Use it for rates, proportions, ratios, percentages and anything measured on a logarithmic scale [1].
  • Do not use it for values that add together, and do not use it with zero or negative numbers.

The Formula

For a set of $n$ positive values $x_1, x_2, \dots, x_n$, the geometric mean is:

$$\text{GM} = \left( \prod_{i=1}^{n} x_i \right)^{1/n} = \sqrt[n]{x_1 \times x_2 \times \dots \times x_n}$$

Each symbol means the following.

SymbolMeaning
$x_i$The $i$th value in the data set. Every value must be positive.
$n$The number of values in the data set.
$\prod$Product notation. Multiply all the values together.
$1/n$The exponent that takes the $n$th root of the product.

The name comes from geometry. The geometric mean of two numbers is the side length of a square whose area equals the area of a rectangle with those two side lengths. For 4 and 9, the rectangle has area 36 and the square has side 6, so the geometric mean is 6 [1]. With three numbers, it is the side of a cube with the same volume as a rectangular box with those side lengths [1].

How to Calculate It Step by Step

  1. Confirm every value is positive. A single zero makes the geometric mean zero, and negative values make it undefined.
  2. Multiply all the values together to get the product.
  3. Count how many values you have. That count is $n$.
  4. Take the $n$th root of the product. On a calculator, raise the product to the power $1/n$.
  5. If the values are growth factors, subtract 1 and multiply by 100 to express the result as a percentage rate.

For two values the $n$th root is a square root. For three values it is a cube root. For five values you raise the product to the power $1/5$.

Worked Example

Suppose you track five annual investment growth factors over five years. A growth factor of 1.10 means the investment grew 10% that year, and 0.95 means it fell 5%.

YearGrowth Factor
Year 11.10
Year 20.95
Year 31.20
Year 41.05
Year 51.15

The growth factors are [1.1, 0.95, 1.2, 1.05, 1.15].

Step 1. Multiply the factors.

$$1.1 \times 0.95 \times 1.2 \times 1.05 \times 1.15 = 1.5142$$

Step 2. Count the factors. There are $n = 5$.

Step 3. Take the fifth root of the product.

$$\text{GM} = (1.5142)^{1/5} = 1.0865$$

The geometric mean growth factor is 1.0865. As an annual return that is $(1.0865 - 1) \times 100 = 8.6518\%$.

For comparison, the arithmetic mean of the same factors is $(1.1 + 0.95 + 1.2 + 1.05 + 1.15) / 5 = 1.0900$, which is 9.0000% per year. The arithmetic mean is higher, and it overstates the actual compounded performance.

Here is the same calculation in Python.

import math
factors = [1.10, 0.95, 1.20, 1.05, 1.15]
gm = math.prod(factors) ** (1/len(factors))
print(round(gm, 4))  # 1.0865

Output:

1.0865

How to Interpret the Result

The geometric mean of 1.0865 is the single constant factor that would produce the same five-year outcome as the five different factors. If your investment had grown by exactly 8.6518% every year for five years, it would end at the same value as the actual sequence.

This is why the geometric mean is the honest average for compounding. The arithmetic mean of 1.0900 describes a world where you earn 9% every year, and that world ends at a different total. The gap between the two averages grows as the values spread out. When a set of numbers is spread apart while keeping the arithmetic mean fixed, the geometric mean falls [3].

The same logic applies to any multiplicative process. Population growth rates, interest rates, inflation rates, dilution factors and laboratory fold-changes all combine by multiplication, so the geometric mean is the appropriate center [3][2].

Doing It in Software

Excel. The GEOMEAN function takes a range of positive numbers and returns the geometric mean. For values in cells A1 through A5, the formula is =GEOMEAN(A1:A5). Excel also has AVERAGE for the arithmetic mean, so you can place the two side by side.

R. The geometric.mean function in the psych package computes it directly. Without extra packages, exp(mean(log(x))) gives the same result for a vector x, because the geometric mean equals the exponential of the arithmetic mean of the logs.

Python. Use math.prod with an exponent, as shown above, or scipy.stats.gmean from SciPy. Both expect positive values.

If you want to check a small data set by hand, the Mean, Median & Mode Calculator handles the arithmetic side quickly, and you can compare its output with a geometric mean you compute yourself.

Common Mistakes

  • Using the geometric mean on values that add. If your quantities sum to a total, such as monthly sales in dollars, use the sample mean instead. The geometric mean answers a product question, not a sum question [2].
  • Averaging percentage returns directly. A return of +10% is a factor of 1.10, not the number 10. Convert percentages to factors before multiplying, then convert back at the end.
  • Including zero or negative values. The product becomes zero or the root of a negative number is undefined. If a value is genuinely zero, the geometric mean is zero. If it is negative, the geometric mean does not apply.
  • Assuming the geometric mean equals the arithmetic mean. It is always smaller unless every value is identical [3][1]. Reporting the arithmetic mean for compounding data overstates the result.
  • Mixing up the geometric mean with the geometric distribution. They share a word and nothing else. The geometric distribution models the number of trials until a first success.
  • Forgetting to take the nth root. Multiplying the values and stopping there gives the product, not the mean. The root is what makes it an average.

Limitations

The geometric mean only works on positive numbers. A single zero collapses the result to zero, and negative values make it undefined in the real numbers. This rules it out for data sets that contain losses expressed as negative numbers, temperature readings on the Celsius scale, or any measurement with a true zero point that can be crossed.

It also hides variation. Two data sets can share the same geometric mean while having very different spreads, so the geometric mean alone tells you nothing about volatility or risk. For investment data, a high geometric mean with wild swings is a different experience from a steady one. Pair it with a dispersion measure such as the mean and standard deviation when you need to describe the full picture. Finally, the geometric mean is sensitive to small values, because a value near zero drags the product down sharply.

Frequently Asked Questions

What does geometric mean mean in plain language?

It is the average value you would need if every item in a list were identical and the items multiplied together. For example, if three growth factors multiply to 2, the geometric mean is the single factor that, applied three times, also gives 2. It is the multiplicative counterpart of the ordinary average.

When should I use the geometric mean instead of the arithmetic mean?

Use the geometric mean when the values combine by multiplication, such as growth rates, interest rates, ratios or percentages [1]. Use the arithmetic mean when the values combine by addition, such as heights, weights or totals. A quick test: if the question is "what single value gives the same product," use the geometric mean [2].

Can the geometric mean be larger than the arithmetic mean?

No. The geometric mean is always less than or equal to the arithmetic mean for positive numbers, and the two are equal only when every value is the same [3][1]. The more the values differ from each other, the wider the gap becomes.

What is the formula for the geometric average?

The formula is $\text{GM} = (x_1 \times x_2 \times \dots \times x_n)^{1/n}$, where $n$ is the number of values. Multiply all the values, then take the $n$th root of the product. For two values it is the square root of their product, and for three values it is the cube root.

How is the geometric mean related to logarithms?

The geometric mean equals the exponential of the arithmetic mean of the logarithms: $\text{GM} = \exp\left(\frac{1}{n}\sum \ln x_i\right)$. This is why it suits data measured on a logarithmic scale [1]. It also explains why you take the arithmetic mean of logged values when you transform data, and the geometric mean when you leave the data raw.

Can I compute the geometric mean of a single value?

Yes, and the answer is that value itself. With $n = 1$, the product is just the value and the first root of it is unchanged. The geometric mean only becomes interesting once you have two or more values that differ from each other.

References

  1. Geometric Mean
  2. Question Corner -- Applications of the Geometric Mean
  3. Geometric mean - Wikipedia

Further Reading

Related Articles