Skip to content

Log difference

A log difference is an exact log ratio for positive observations. Learn time aggregation, percentage conversion, unit invariance and price-adjustment pitfalls.

A log difference is the change in the natural logarithm of a positive variable between two observations:
gt=Δln⁡xt=ln⁡xt−ln⁡xt−1=ln⁡(xtxt−1),xt>0,xt−1>0.g_t=\Delta\ln x_t=\ln x_t-\ln x_{t-1} =\ln\left(\frac{x_t}{x_{t-1}}\right), \qquad x_t>0,\quad x_{t-1}>0.
It measures a proportional change rather than an absolute change. For a consistently measured asset price with no intervening distributions, it is the log return. For revenue, output or a price index, the same operation measures log growth. The first difference of a level, by contrast, retains the level's units: a price difference is measured in currency per share.

The ratio is exact; the percentage interpretation is approximate

Write the ordinary proportional change, or simple return, as Rt=xt/xt−1−1R_t=x_t/x_{t-1}-1. Then

gt=ln⁡(1+Rt),Rt=egt−1.g_t=\ln(1+R_t),\qquad R_t=e^{g_t}-1.
Thus 100gt100g_t is approximately the percentage change when the move is small. The exact percentage change is 100(egt−1)100(e^{g_t}-1). A rise from 100 to 110 gives gt=ln⁡(1.1)≈0.09531018g_t=\ln(1.1)\approx0.09531018: about 9.531 log points when multiplied by 100, versus a simple return of 10%. State the scale explicitly; a decimal log difference of 0.01 and a displayed value of 1 after multiplication by 100 describe the same log change.

The approximation follows from ln⁡(1+R)=R−R2/2+O(R3)\ln(1+R)=R-R^2/2+O(R^3) near zero. It is less reliable for large moves. A log difference is not the logarithm of the ordinary difference: ln⁡(xt−xt−1)\ln(x_t-x_{t-1}) would fail even for a perfectly valid decline between two positive observations.

A round trip in percentages is not a round trip in wealth

Suppose a hypothetical share closes at USD 100, USD 110 and USD 99 over two consecutive periods. There are no dividends, splits or costs.

IntervalSimple returnLog difference, decimal
100 to 110+10%0.09531018
110 to 99−10%−0.10536052
Full interval, 100 to 99−1%−0.01005034

The loss is applied to 110, a larger base than the initial 100. Adding 10%+(−10%)10\%+(-10\%) gives zero, but the full-period simple return is

(1+R1)(1+R2)−1=1.10×0.90−1=−0.01.(1+R_1)(1+R_2)-1=1.10\times0.90-1=-0.01.

Log differences add exactly across consecutive observations:

∑t=1Tgt=ln⁡xT−ln⁡x0=ln⁡(xTx0).\sum_{t=1}^{T}g_t =\ln x_T-\ln x_0 =\ln\left(\frac{x_T}{x_0}\right).

Here the unrounded sum is ln⁡(0.99)≈−0.01005034\ln(0.99)\approx-0.01005034. Exponentiating that sum and subtracting one recovers the −1% simple return. The identity needs no assumption of independent or normally distributed returns.

Synthetic prices USD 100, USD 110 and USD 99 generate simple returns plus 10% and minus 10%; log differences 0.09531018 and minus 0.10536052 add to minus 0.01005034, equivalent to a minus 1% compounded simple return.
Synthetic prices USD 100, USD 110 and USD 99 generate simple returns plus 10% and minus 10%; log differences 0.09531018 and minus 0.10536052 add to minus 0.01005034, equivalent to a minus 1% compounded simple return.
Original synthetic example, with no distributions or costs. The waterfall adds decimal log changes; the price panel shows the corresponding USD-per-share path.
This is aggregation through time for the same series. Adding log returns of different assets does not generally produce a portfolio return; portfolio weights act on simple returns under the usual one-period holdings assumptions.

Units disappear only when they are consistent

Multiplying every observation by the same positive constant cc leaves the log difference unchanged:

ln⁡(cxt)−ln⁡(cxt−1)=ln⁡(xt/xt−1).\ln(cx_t)-\ln(cx_{t-1})=\ln(x_t/x_{t-1}).

Prices quoted consistently in cents therefore produce the same log differences as prices quoted consistently in dollars. Formally, logging xt/x∗x_t/x_* relative to a fixed positive reference level x∗x_* also avoids taking a logarithm of a dimensional quantity; the reference cancels on differencing.

A time-varying conversion does not cancel. Translating foreign-currency prices into domestic currency adds the exchange-rate log change to the local-price log change. That is a different investment exposure. Using base-10 logarithms also changes the numerical scale: divide the natural-log difference by ln⁡10\ln 10 to obtain the base-10 difference.

A log difference describes the entire observation interval. Divide by elapsed years to report an average continuously compounded annual rate. Across irregular observation gaps, the same log difference can represent very different annual rates. Summing observed consecutive log differences still yields the endpoint change, but a missing date does not become an observed zero-return day.

Check what the observations represent

Both observations must be strictly positive for the real-valued log difference above. Zero has no finite logarithm; a negative observation has no real logarithm. Even two negative observations with a positive ratio do not make their separate real logarithms defined. A total loss from positive wealth to zero corresponds to a log return tending to negative infinity.

For series that can cross zero—such as profit, a spread or some futures prices—choose a transformation suited to the economic question. Adding an arbitrary constant before logging changes the measured proportional change and makes it depend on the chosen offset and units. It does not preserve the original log-return interpretation. Taking absolute values discards the sign.

Prices also need a consistent economic basis:

  • Splits: in an otherwise unchanged two-for-one split, a USD 100 share becomes two USD 50 shares. Logging the unadjusted quotes reports ln⁡(0.5)\ln(0.5), despite unchanged position value. Use a consistently split-adjusted series. This is the share-count mechanism described by Investor.gov.
  • Dividends: a price log difference alone measures price return. For example, a USD 100 share ending at USD 98 while paying USD 2 cash at the interval end has a −2% price return but a zero total return before costs. To study total return, use a documented reinvested total-return series or explicitly account for distributions. Check the provider's adjustment and reinvestment conventions before treating an “adjusted close” as that series.
Finally, logging and differencing are transformations, not proof of stationarity. Changing volatility, structural breaks and residual dependence can remain. The member lesson Financial Return Characteristics develops return conversion, time versus portfolio aggregation and the limits of Gaussian assumptions; a public preview is available.

Sources

Last updated
  • logarithms
  • growth
  • returns
  • time series
  • data transformations
← Back to the glossaryBack to top ↑