Time series trends in 3D

A three-dimensional line chart on a stand, showing a blue line and an orange line with data points on a grid scaled 0 to 100.Drag to turn

A time series is a set of measurements of one quantity taken at ordered points in time. A line chart plots these values against time and joins them with line segments, so that the trend, or long-run direction, can be seen.

What a time series and a line chart show

A time series records a variable at regular intervals, such as daily temperature, monthly sales or yearly population. Time goes on the horizontal axis and the measured value goes on the vertical axis. Each point is joined to the next by a straight segment.

The joining lines suggest that the quantity changes continuously between observations. This fits data such as temperature. It is only an approximation for counts recorded once a month, so a line chart should be used when the order of the points matters.

Trend, seasonality and noise

Analysts usually split a series into three parts. The trend is the long-run upward or downward movement. Seasonality is a pattern that repeats at a fixed period, such as higher ice cream sales every summer. Noise is the irregular variation left over.

A common way to reveal the trend is a moving average, which replaces each value with the mean of nearby values. This smooths out noise and, if the window equals the seasonal period, also removes seasonality. A simple trend can also be fitted with a straight line, as in linear regression on time.

Worked example: a three-month moving average

Suppose monthly sales, in units, are 10, 14, 12, 18, 16, 20 for months 1 to 6. The three-month moving average at month 2 is (10 + 14 + 12) / 3 = 36 / 3 = 12. At month 3 it is (14 + 12 + 18) / 3 = 44 / 3, about 14.7.

At month 4 it is (12 + 18 + 16) / 3 = 46 / 3, about 15.3. At month 5 it is (18 + 16 + 20) / 3 = 54 / 3 = 18. The smoothed values 12, 14.7, 15.3 and 18 rise steadily, while the raw values zigzag. The trend is upward even though sales fell in months 3 and 5.

Common misconceptions

A rising line does not show that one variable causes another. Two unrelated series can both trend upward over time and appear linked. A trend also should not be extended far beyond the observed data, because the pattern may change.

The look of a chart depends on its scales. A vertical axis that does not start at zero can make small changes look large. Unevenly spaced dates drawn at equal spacing also distort the shape of the trend.

Where line charts and trends appear

Line charts are used for stock prices, climate records, hospital admissions, website traffic and economic indicators such as inflation. Forecasting methods, including moving averages and exponential smoothing, build on the same decomposition into trend, seasonality and noise.

Key terms

Time series
A set of observations of one variable recorded in time order.
Trend
The long-run upward or downward direction of a series.
Seasonality
A pattern that repeats over a fixed period.
Noise
Irregular variation that is not trend or seasonality.
Moving average
The mean of a fixed number of neighbouring values, used to smooth a series.
Line chart
A graph of values against time with consecutive points joined by line segments.

Common questions

When should a line chart be used instead of a bar chart?

A line chart suits ordered, continuous or regularly spaced data such as time, where the shape of change matters. A bar chart suits comparing separate categories.

Why does a moving average have fewer points than the original series?

The first and last values lack enough neighbours for a full window. A three-point average, for example, cannot be computed at the first or last point.

Does a trend line predict the future?

It can give a rough projection if conditions stay similar. Its reliability falls the further it is extended beyond the data.

Learn this with a tutor

Sidechair's AI tutor will teach this topic in 3D. Join the waitlist for early access.

We'll only email you about Sidechair. Read our privacy policy.