Why Observation Order Matters
A set of measurements can have the same values and the same overall distribution while telling very different stories. If a claim-related measure rises steadily, shifts upward suddenly, or has one unusually high reading, those patterns can be obscured when the observations are sorted by size or summarized without their order. A time-ordered plot keeps the sequence visible.
This is useful during data exploration: a jump may point to a change in measurement conditions, a gradual movement may suggest a developing pattern, and a single spike may deserve a data-quality check. The plot helps describe what happened in the recorded sequence. On its own, it does not establish why it happened.
Constructing the Plot
Let \(y_t\) denote a numeric measurement at ordered position \(t\), where \(t=1,\ldots,n\). If the observations are recorded at regular dates, use those dates on the horizontal axis. If only their order is known, use the observation number. The vertical axis should name the measured quantity and its units.
In R, a simple plot for a vector of measurements y is plot(seq_along(y), y, type="b", xlab="Observation order", ylab="Measure"). The option type="b" displays both points and connecting segments. If an actual date variable is available, plot(date, y, type="b", xlab="Date", ylab="Measure") uses calendar time instead. The date values must be in chronological order and paired with the correct measurements.
Use a line connecting observations only when the order is meaningful. Connecting values in an arbitrary row order can create a pattern that belongs to the file layout rather than the process. Likewise, do not sort observations by the measured value before plotting: that removes the very sequence the plot is meant to show. A time-ordered plot is not a substitute for checking whether dates and values have been matched correctly.
Worked Example: Reading Consecutive Changes
A hypothetical service team records a processing measure for eight consecutive work periods. The values, in minutes, are 40, 42, 41, 43, 43, 45, 44, and 46. Use the ordered values to describe the local movement and calculate the changes between consecutive periods.
Method. Keep the observations in their recorded order and subtract each value from the next. Define the first difference at position \(t\) as \(d_t=y_t-y_{t-1}\), for \(t=2,\ldots,n\).
The calculations are \(42-40=2\), \(41-42=-1\), \(43-41=2\), \(43-43=0\), \(45-43=2\), \(44-45=-1\), and \(46-44=2\). Thus, the seven changes are 2, −1, 2, 0, 2, −1, and 2 minutes.
The changes include small reversals and a tie, but four of the seven are positive. The values generally move upward over these eight observations, although they do not increase at every step. This is a description of this short sequence, not evidence of a long-run trend.
Check. There are eight observations and therefore seven consecutive changes. Counting the positive entries gives four; the zero is not positive, and the two negative changes are reversals. A common mistake is to count the zero or overlook one of the reversals and report five positive changes.
Recognizing Different Shapes
A time-ordered plot is useful because it shows where changes occur, not just how large or dispersed the values are. Four patterns are especially important to distinguish during data exploration.
- Gradual trend: values tend to move upward or downward over many consecutive observations. Small reversals can occur; a trend does not require every point to move in the same direction.
- Periodic pattern: a similar sequence of rises and falls repeats at a regular or approximately regular interval. A short sequence may suggest repetition, but may not be long enough to establish a stable period.
- Abrupt shift: values move to a noticeably different level around one point in the sequence and remain near that level afterward. The shift’s location can be visible even when the observations within each level vary.
- Isolated spike: one observation stands out relative to its immediate neighbors, which return to their previous range. A spike might be a genuine event or a recording problem; the plot alone cannot decide which.
These patterns can overlap. For example, measurements may rise gradually while also showing repeating short-term variation. The task at this stage is to describe the visible sequence accurately, not to force every plot into only one category.
Worked Example: Identifying a Sudden Level Change
A hypothetical administrator records a monthly processing time, in hours, for twelve consecutive months. The first six values are 10, 11, 9, 10, 10, and 11. The next six are 15, 16, 14, 15, 15, and 16. Determine whether the sequence is consistent with an abrupt change in level and quantify the difference between the two halves.
Method. Plot all twelve observations in month order. Then calculate the mean for each six-month segment as a compact description of its level. This comparison describes the two segments; it does not by itself test whether the apparent change is statistically significant.
For the first segment, the sum is \(10+11+9+10+10+11=61\), so its mean is \(61/6=10.1667\) hours to four decimal places. For the second segment, the sum is \(15+16+14+15+15+16=91\), so its mean is \(91/6=15.1667\) hours to four decimal places.
The difference between the segment means is \(15.1667-10.1667=5.0000\) hours to four decimal places. The plot would show the first six values fluctuating around a lower level and the last six around a higher one. This pattern is consistent with an abrupt upward shift near the boundary between months six and seven.
Check and trap. The two segments each contain six months, and their totals differ by \(91-61=30\) hours, so their mean difference must be \(30/6=5\) hours. A common mistake is to compare the last value in the first segment, 11, with the first value in the second, 15, and call the shift 4 hours. That is the boundary-to-boundary change, not the difference between the segment means. Neither calculation establishes the cause of the observed change.
Worked Example: Distinguishing a Repeating Pattern From a Trend
A hypothetical monitoring system records twelve consecutive readings: 12, 14, 12, 14, 12, 14, 12, 14, 12, 14, 12, and 14. Describe the visible pattern and calculate the mean. Would the sequence, by itself, support a claim of steady upward movement?
Method. Plot the values in order and inspect whether similar movements recur. Calculate the mean using the sum of the observations divided by their count.
Each adjacent pair consists of one 12 and one 14. There are six such pairs, so the total is \(6(12+14)=6(26)=156\). With twelve observations, the mean is \(156/12=13\).
The consecutive changes are \(+2,-2,+2,-2,+2,-2,+2,-2,+2,-2,+2\). The same two-step rise-and-fall pattern repeats throughout the sequence. The plot therefore suggests periodic variation with a repeated two-observation cycle, not steady upward movement. Its mean of 13 summarizes the center but does not convey the alternating pattern.
Check and trap. The first and last readings are both 12, and each two-observation pair totals 26, consistent with the mean of 13. A common mistake is to look only at the high readings or only at the low readings, which can make one part of the sequence seem to rise. The full ordered plot shows that both values recur without a sustained increase.
Worked Example: Finding an Isolated Spike
A hypothetical sensor produces eight consecutive readings: 30, 31, 29, 30, 31, 45, 29, and 30. Identify the feature that a time-ordered plot reveals and compare the overall mean with the mean after excluding the sixth reading for diagnostic purposes.
Method. First inspect the sequence and its immediate neighbors. Then calculate the two means. Excluding a value here is only a diagnostic comparison; it is not a recommendation to delete a valid observation.
The sixth reading is 45, while the fifth and seventh readings are 31 and 29. The change into the sixth reading is \(45-31=14\), and the change out of it is \(29-45=-16\). The sharp rise followed immediately by a sharp fall makes the sixth reading look like an isolated spike.
The sum of the seven other readings is \(30+31+29+30+31+29+30=210\), so their mean is \(210/7=30\). Including the spike gives a total of \(210+45=255\), and the overall mean is \(255/8=31.875\). Thus the single high reading raises the mean from 30 to 31.875.
Check and trap. The overall total is 255, and \(31.875\times8=255\); the mean excluding the sixth value is based on 210 divided by seven. A common mistake is to remove the spike automatically because it looks unusual. The plot identifies a value worth checking against the source record and measurement context; it does not tell us whether the value is erroneous or should be excluded.
Why the First Difference Helps
The first difference \(d_t=y_t-y_{t-1}\) expresses the change from one observation to the next in the measurement’s units. It is a numerical description of local movement: positive values indicate increases, negative values indicate decreases, and zero indicates no change between consecutive observations.
A simple piecewise-level model explains why this can help locate an abrupt shift. Suppose, only as a descriptive approximation, that observations before a boundary have level \(\mu_1\), observations after it have level \(\mu_2\), and each observed value differs from its level by an error term. The errors need not be zero in any particular observation; assume their average is zero within each level for this justification. No distributional assumption is required for the algebra.
At the boundary \(t=k+1\), subtract the value immediately before the boundary from the value immediately after it. The level change remains, along with the difference between the two errors:
If the levels are the same, the level-change term is zero. If the levels differ, the boundary difference includes \(\mu_2-\mu_1\), which can make that location stand out. This is a justification for inspecting consecutive changes, not a guarantee: ordinary noise can create a large difference, and an actual shift can be obscured by substantial variation.
Check that each measurement is paired with the correct time or observation number and that the records are sorted in the intended order.
Label the axes and units, then describe gradual movement, repetition, possible level changes, and individual spikes in context.
Check an unusual interval or reading against relevant records and context before suggesting an explanation or changing the data.
Common Misreadings and Practical Limits
A distribution summary can reveal where values lie but discards their order. Two sequences containing the same values have the same mean and range, for example, even if one alternates between low and high values and the other places all low values before all high values. Plotting the ordered observations addresses that limitation by showing adjacency and timing.
The horizontal axis deserves particular care. If observations arrive at uneven intervals, plotting them at equally spaced observation numbers makes a two-day gap look the same width as a two-month gap. Use the actual time values when the elapsed time matters. If only the order is available, say that the horizontal axis represents order, not elapsed time.
A visible boundary is not automatically a known intervention, and a spike is not automatically an error. Changes in recording procedures, population composition, or exposure can coincide with changes in the measured value. The plot can suggest where to investigate, but causal explanations require evidence beyond visual inspection. This is especially important when describing hypothetical insurance or operational measures: a pattern in a plotted sequence should not be presented as proof of a real-world cause.
A time-ordered plot is aligned with the SOA Exam PA (Predictive Analytics) syllabus because it supports sound data exploration: preserve the sequence, describe the pattern, and separate what the graph shows from what remains uncertain.
Check Your Understanding
For each problem, state the pattern or calculation requested using the observations in their given order.
- A hypothetical meter records 8, 9, 8, 9, 8, and 9 at six consecutive times. What repeating pattern is visible, and what is the mean? (Answer: Alternation with period two; mean \(51/6=8.5\).)
- A hypothetical monthly measure is 4, 5, 4, 5, 7, 8, 7, and 8. Calculate the means of the first and last four observations and their difference. (Answer: First mean \(18/4=4.5\), last mean \(30/4=7.5\), difference \(3\).)
- A hypothetical sensor records 18, 20, 19, 21, 20, 35, and 19. Which observation most resembles an isolated spike, and what are the changes into and out of it? (Answer: The sixth observation, 35; the changes are \(35-20=15\) and \(19-35=-16\).)
- A numeric measure is recorded at dates January 1, January 2, January 8, and January 9. If elapsed time matters, should the horizontal axis use equally spaced observation numbers or the actual dates? (Answer: Use the actual dates, since the intervals are unequal.)
- A sequence is 10, 11, 12, 13, and 14. What is its mean, and what does its ordered shape suggest? (Answer: Mean \(60/5=12\); a steady gradual increase across the five observations.)