Time Series in Finance: Why Ordered Data Behaves Differently
A time series is a set of observations that each carry a date, and the order of those dates is part of the data rather than a way of filing it. Sort the Nakshatra unit's 72 monthly changes from smallest to largest and the average of 1.00 per cent a month, the spread of 5.00 per cent and the closing price of Rs 187.4539/- do not move at all. Everything else does.
The six year record below was written rather than measured. Somebody chose 72 whole numbers, wrote down the rule that produces them, and every price, count and average printed here falls out of that rule and out of nothing else. Figures run to four decimal places for one reason: a reader who redoes the arithmetic should land on the same digits, or else find that a slip has been made.
Consider something most people already do without calling it anything. A tea stall outside one office building sold 40 cups today. The same stall sold 40 cups yesterday too. The two counts are identical, and yet the second 40 arrived after the first one, so nobody who runs a stall would say the two days carried the same news. Steady is a fact about the pair in that order. Reversed, steady is still true. But a 40 arriving after a run of 90, 80, 65 and 52 means something a stall owner would lose sleep over.
The position an observation sits in is not packaging around the observation, it is a second thing the observation is made of. The 40 is one fact. The place it sits in the queue is another. Removing the second is not tidying the data, it is deleting half of it.
What is a time series, and how is it different from a set of numbers?
A time series is a set of observations where each one carries a date, and the observations are kept in the order those dates put them in. Every word there is doing work. Each observation carries a date, so no two of them are interchangeable. The observations are kept in the order the dates give, so the record has a first, a next and a last. And nothing else about them is special: the observations themselves can be rupees, counts, temperatures or cups of tea.
A set of numbers with no order is a different object. Ask it what its average is and it answers. Ask it what its largest member is and it answers. Ask it what came after the largest member and it has nothing to say. A plain set has no notion of after at all. The questions a plain set can answer are exactly the questions that do not use the word after, and almost every question worth asking about a record over time uses that word or a synonym for it.
The test takes one line and applies to any figure anybody hands over. The rows are shuffled. If the figure comes out the same, the figure was never about the order. If it moves, the order was carrying it. The shuffle separates the figures that describe a series from the figures that describe a heap, and what follows is that test run on one record until the difference is impossible to miss.
When 72 monthly percentage changes are put in line from the smallest to the largest, and the price path is rebuilt from the same starting figure, what happens to the price it finishes at?
What does the six year record actually contain?
One record carries every figure below, so it is worth meeting properly. The six year record holds 72 monthly observations of the Nakshatra unit, an invented instrument. Its first observation is the month that closed on 31 January 2019 and its last is the month that closed on 31 December 2024, counted out from an opening markWhere the counting begins. Nobody watched this happen: a figure of Rs 100.00/- was simply fixed to the last day of December 2018 so that the first month would have something to work on. of Rs 100.00/- on 31 December 2018. Each observation is that month's percentage change, and the price at any month is the opening mark carried forward through every change up to it.
Its mean monthly change is 1.00 per cent and its spread is 5.00 per cent. The mean and the spread are not discoveries. Both numbers were settled for the Nakshatra unit before the record existed, and the record was written to sit exactly on them. The centre and the width are pinned by construction, so every difference shown below comes from the order and from nothing else. There is no second cause available.
One point of housekeeping while the record is in view. The spread of 5.00 per cent divides by 72, not by 71. The six year record is a complete record of 72 months, not a sample of months used to guess at something larger, and the two denominators answer different questions. Dividing by 71 instead would give 5.0351 per cent here, and that figure would be answering a question this guide never asks.
The raw material, before any arithmetic: the largest single month is 16.00 per cent in October 2022 and the smallest is a fall of 13.00 per cent in July 2024. Of the 72 months, 38 rose, 28 fell and 6 finished level. The longest unbroken run of falling months is four. Carried forward from Rs 100.00/-, the price reaches its lowest at Rs 96.8923/- in August 2019 and its highest at Rs 238.6196/- in November 2023, and it closes at Rs 187.4539/-, up 87.4539 per cent over the six years.
The grid is the one place where the record is shown rather than summarised, so it repays a moment's attention. The top half is pale. The bottom half is not. Four of the first 36 months moved by 6 per cent or more; fifteen of the last 36 did. No spread has been stated and no average shown, and yet the two halves of this record are already visibly unlike each other. Hold on to that difference. The single figure of 5.00 per cent that describes the whole record cannot see it, and neither can any other figure that survives a shuffle.
Which months does the six year record run over, and how many observations does it hold?
What survives when the record is put in a different order?
Take the same 72 changes. Add nothing, remove nothing, alter nothing. Line them up from the smallest to the largest instead of from January 2019 to December 2024, and carry the same Rs 100.00/- opening mark through them in that new order. Three figures come out exactly as before.
A mean adds the members up and divides, and addition does not care what order it adds in, so the mean is 1.00 per cent. The spread is 5.00 per cent for the same reason, one step further along. Each member's distance from the mean is unchanged, and those distances are then squared and averaged. Averaging is addition again. Neither of those two is surprising once stated.
The third one usually does. The price finishes at Rs 187.4539/-, identical to the paisaA rupee split into a hundred parts gives one paisa each. Two figures said to agree at that level match in their second decimal. Four decimal places, as printed here, is stricter again. and in fact identical for as many decimal places as anybody cares to print. That is not a near miss and it is not luck. Building a price path is multiplication: the path starts at Rs 100.00/-, multiplies by 1.02 for a 2 per cent month, by 0.96 for a 4 per cent fall, and so on for 72 factors. The finishing price is the opening mark times the product of all 72 factors, and a product does not depend on the order of its factors. Two rupees times three rupees times five is thirty, whichever way round it is written. Rearranging the record rearranges the multiplication and cannot touch the answer.
The everyday version is a household paying rent. If the rent rises 10 per cent one year and 5 per cent the next, the rent at the end is the same as if it had risen 5 per cent first and 10 per cent second. The household lived through something quite different in each case: which year the squeeze landed in, and how much slack there was when it did. The endpoint is order blind and the journey is not.
The mean of the six year record is 1.00 per cent and its spread is 5.00 per cent. Name two other records that those same two figures describe just as accurately.
What is destroyed the moment the order changes?
Now the other column of the same comparison, and it is worth saying once more that not a single observation has been added, removed or altered. Only their positions have moved.
The lowest price the path ever reaches falls from Rs 96.8923/- to Rs 34.2191/-. In date order the record dipped a little under its opening mark and recovered; sorted, it takes every falling month first and grinds down to roughly a third of where it began before a single good month arrives. The months spent below the opening mark go from 5 to 65. A move of that size is not a small change in a statistic. The gap separates a record that barely went underwater from one that spent nine tenths of its life there.
The two three year stretches change character completely. In date order both average exactly 1.00 per cent. Sorting puts all the poor months in one stretch and all the good ones in the other, so the first stretch averages a fall of 2.8333 per cent a month and the second a rise of 4.8333 per cent. And the autocorrelationA single figure, usually between minus one and one, saying how closely each observation resembles the one a fixed number of places before it. How it is computed and read is covered separately. at a one month gap moves from 0.2011 to 0.8683. Sorting has forced every month to sit next to a month of almost the same size, and nothing else was available.
Because that last figure is a number rather than a picture, it needs a convention stated with it, and this is a habit worth forming now. Autocorrelation has more than one standard recipe and they do not agree. Every autocorrelation in this guide uses one average for the whole record and divides the summed paired products by the record's total sum of squared deviations. A second common recipe correlates the record against a shifted copy of itself and gives each of the two columns its own average. On the six year record that second recipe reads 0.2114 rather than 0.2011, and on the sorted version 0.9871 rather than 0.8683. Neither is wrong. The two recipes answer slightly different questions, and the disagreement widens as the gap between the paired observations grows. A figure of this kind quoted without its recipe cannot be checked by anybody.
One caution costs nothing to carry. Run that same calculation at a twelve month gap on this record and it reads 0.0022, as close to nothing as makes no difference. The six year record nevertheless carries a large and genuinely repeating calendar pattern: its six Januaries average 5.00 per cent and its six Junes average a fall of 3.00 per cent. So a small autocorrelation at a twelve month gap is not evidence that a calendar pattern is absent. How a repeating pattern is actually detected is covered separately.
How do those two orders compare figure by figure?
The whole argument sits in one table. Five figures, computed twice on the identical 72 observations. Three of them do not move at all and two of them become unrecognisable. The date order column is exactly what the panel below starts on.
| Figure | In date order | Sorted smallest to largest |
|---|---|---|
| Mean monthly change | 1.00 per cent | 1.00 per cent |
| Spread of the changes | 5.00 per cent | 5.00 per cent |
| Closing price | Rs 187.4539/- | Rs 187.4539/- |
| Lowest price on the path | Rs 96.8923/- | Rs 34.2191/- |
| Months below the opening mark | 5 | 65 |
| Observations changed to get from one column to the other | none | none |
The lowest price on the path falls from Rs 96.8923/- to Rs 34.2191/- when the record is sorted. How many of the 72 observations had to be changed to produce that?
Which four things can only exist in an ordered record?
If order carries something, it is fair to ask what. Four properties turn up again and again in records of this kind, and every one of them needs an order to even be stated. All four are present in the six year record, and each is built in full separately.
A direction that persists. The price left the opening mark of Rs 100.00/- and finished at Rs 187.4539/-, up 87.4539 per cent, and only 5 of its 72 months sat below where it started. Separating a direction of that kind from ordinary noise is covered separately.
A pattern that repeats on a fixed calendar period. The six Januaries in this record average 5.00 per cent and the six Junes average a fall of 3.00 per cent. Detecting such a pattern properly, and removing it under the name seasonal adjustmentSubtracting from each observation the part attributable to which calendar month it falls in, so that months can be compared with one another. The method and what it removes are covered separately., is covered separately.
Memory. This means an observation carrying information about the one that follows it. The six year record's one month autocorrelation is 0.2011 on the recipe named above, so one month tells a little, though not much, about the next. Lining a record up against its own past is covered separately.
A spread that differs from one stretch to another. The first three years carry a spread of 3.00 per cent and the last three carry 6.4031 per cent, 2.1344 times as wide. A single figure of 5.00 per cent for the whole record sits between them and describes neither stretch. Volatility that itself varies is covered separately.
Every one of those four is invisible to a mean and a spread, and every one of them survives in the record and dies in the shuffle. Nothing about that is peculiar to this record. The four properties are exactly that: statements about position, made in a language that a summary of the values has no words for.
Which one of these four cannot exist at all inside a set of numbers that carries no order: a mean, a spread, a pattern that repeats every twelve observations, a largest value?
Why do the tools built for unordered data strain here?
The mean, the spread and the interval around an estimate were all built on a quiet assumption that is easily missed as it is being made: that the observations do not lean on each other. Each one arrives carrying news of its own. Under that assumption, 72 observations really do supply 72 separate items of information, and the arithmetic that turns them into a range is honest.
Records that come in sequence usually break the assumption. If this month resembles last month, then this month's observation is partly a repeat of news already in hand, and 72 observations supply fewer than 72 items of information. A figure computed as though the observations were independent overstates how much the record has pinned down, and the range around it comes out narrower than it deserves to be. It looks more precise than it is, which is the worst direction for an error to run in.
There is a sharper version of the same problem, and it is the reason a fitted line's leftovers get checked at all. Fit a line between two records that each drift steadily, and the fit can report a strong relationship where neither record knew anything about the other. The tell shows up in the residualWhat is left of an observation after a fitted line's prediction for it is subtracted. If the leftovers still carry a pattern, the fit has not captured everything and its reported precision cannot be trusted. column: the leftovers, which are supposed to look like unrelated scatter, instead resemble each other from one row to the next. Ordering can manufacture a relationship out of nothing, and the residual check exists to catch it.
Almost everything that follows in these notes is a response to that problem. Smoothing a record to see through the noise, recomputing a figure over a moving stretch of months under the name rolling windowA fixed length stretch of consecutive observations that slides forward one step at a time, so a figure gets recomputed on the most recent stretch rather than once on everything. Covered separately., testing whether a record sits still enough for the ordinary tools to apply, a test that turns on the unit rootThe name for a level that drifts wherever it happens to go, with nothing tugging it back towards a usual value. Which tools may be pointed at a record turns on this, and the test is covered separately., and turning a level into a change, usually as a log differenceThe difference between the logarithms of two consecutive levels, used instead of a plain percentage change because such differences add up cleanly over many periods. Covered separately.. Each of those is a separate topic and none of them is attempted here.
Both three year stretches of the six year record average exactly 1.00 per cent a month. What does that establish about the two stretches, and what does it fail to establish?
How does one order turn into another without anybody noticing?
Sorting a record smallest to largest is a deliberate act, and nobody does it by accident. There is a much quieter way to lose an order, and it is worth meeting here because it shows that this is a practical problem rather than a thought experiment.
Write the 72 dates the way a great many systems write them, day first: 31-01-2019, 28-02-2019, 31-03-2019 and so on. Now sort that column. If the sort treats those entries as text rather than as dates, it compares them character by character from the left. Character order puts the day of the month first, the month second and the year last. The record that comes out opens at 28-02-2019 instead of 31-01-2019, and 71 of the 72 observations land somewhere other than where they belong.
The thing to notice is how little the record complains. The mean is still 1.00 per cent. The spread is still 5.00 per cent. The product is unchanged, so the closing price is still Rs 187.4539/-, to every decimal place. The lowest price on the path moves only from Rs 96.8923/- to Rs 91.0309/-, and the months below the opening mark go from 5 to 8. Nobody would query a difference that small. Only the month to month autocorrelation shifts noticeably, falling from 0.2011 to 0.0378 on the recipe named earlier. A record whose order has been destroyed can pass every check an analyst was planning to run.
What does the reordering look like when it is done by hand?
The panel below carries the same 72 changes in all three orders. Moving the ordering control leaves the top three readings unmoved while the bottom three change out of recognition. The second control does something different. Walking a cursor along the record shows where each order stands at any point on the way, and a finished figure cannot show that.
Reorder the record and watch which readings refuse to move
Three orderings of the identical 72 monthly changes. Nothing is added, removed or altered between them, and the two reorderings describe nothing that happened.
Educational illustration. All three orderings hold the identical 72 changes, and the two reorderings rearrange those changes without altering one of them. The autocorrelation uses one average for the whole record over the record's total sum of squared deviations, the recipe named earlier.
A colleague argues that the order of rows in a data file is just how it happens to have been stored. Using the six year record, which pair below settles the argument?
The summary that was arithmetically perfect and still described nothing
Somebody writes one sentence about the six year record: the Nakshatra unit moved by 1.00 per cent in an average month, and the spread of its changes was 5.00 per cent. Check it and every word is right. Both figures are exact, not rounded, and they are the two numbers the record was built to sit on.
Now notice what else that sentence describes, with the same exactness. The sorted version spent 65 of its 72 months below the opening mark and dug down to Rs 34.2191/-, and the sentence describes it exactly. The record read backwards from December 2024 reaches a low of Rs 78.5576/- and spends 17 months underwater, and the sentence describes that just as well. The same sentence describes the version a day first text sort produces. The same sentence describes the 72 changes in any arrangement at all, and there are more arrangements of 72 items than anybody has a name for. A sentence that is equally true of a record and of every scramble of that record is not a description of the record.
The cost is specific enough to price. The summary cannot see that the last three years of this record are 2.1344 times as wide as the first three, at 6.4031 per cent against 3.00 per cent. Anyone working from the sentence is working from an average of two stretches, neither of which ever happened: the calm one never had a spread of 5.00 per cent and neither did the rough one. A plan sized on 5.00 per cent was too loose for the first stretch and too tight for the second, and it was never once right.
A habit does better than a warning here. Before a summary of a record is quoted, the analyst asks what that same summary would say about the rows shuffled. If the answer is the same thing, the figure is one about the values and not one about the record, and the summary should say which of the two it is.
Somebody summarises a record and the summary is arithmetically perfect. Give the strongest single reason it can still be a poor description of that record.
What should be asked about any record before it is summarised?
Somebody sends a lender, an analyst or anybody else a file with a date column and a value column, and asks for a view by the end of the day. Five questions, in this order, cost about two minutes and catch most of what goes wrong.
What are the dates, and are they actually in order? Sorting by date, as dates, and checking that the first and last rows are the expected ones is the whole of it. On the six year record the top row is the month that closed on 31 January 2019 and the bottom row the month that closed on 31 December 2024, 72 rows in all. A day first text sort would open at 28 February 2019 instead, and nothing else in the file would look wrong.
What is the gap between observations, and is it the same gap all the way through? Here it is one calendar month, every time, with no month missing and none repeated. A record with a gap in it is a different object from a record without one, and the difference does not announce itself.
Is this a level or a change? Rs 140.8315/- is a level and 5.00 per cent is a change, and almost every tool cares which of the two it has been handed. The two readings are covered separately.
Does the spread look about the same at both ends? On this record it does not: 3.00 per cent over the first three years and 6.4031 per cent over the last three. Any single figure for the whole record is an average of two different regimes.
And what in this figure would change if I shuffled the rows? That last question is the cheapest test on the list, and a figure which survives it was never about the order in the first place. It takes one line of work and it settles exactly which half of the file is being described.
A single figure arrives, computed from a record nobody has seen. What is the cheapest single test of whether that figure says anything about the order?
In one line: the mean, the spread and the closing price of the six year record survive any shuffle at all, and the lowest price on the path, the months spent below the opening mark and the one month autocorrelation do not. The first three describe 72 numbers. The last three describe a record.
Subjects covered separately. The three readings a single record supports and how they differ. Lining a record up against its own past. What makes a repeating pattern a calendar pattern, and how one is stripped back out. Telling a direction apart from noise. What it means for a record to sit still, and the check for it. Why a spread that shifts partway needs handling of its own. And how a level becomes a change. All seven are covered separately. The four properties above were therefore named and pointed at rather than built.
Estimating something about a wider population from a sample of it, and fitting a line between two records, are both built earlier and used here only by name.
Where do these figures come from, if not from a source?
Putting rows in order is arithmetic, and arithmetic has nobody to appeal to. Setting an official name beside numbers that were made up would lend those numbers an authority they have no claim on.
Three things hold the figures up instead, and not one of them rests on trusting anybody. First, the rule that produces the six year record: a steady one per cent, twelve calendar values that cancel each other out over any full year, and an irregular part that widens halfway along. Second, the plain definitions of an average and of a spread, both settled earlier and used here without alteration. Third, the fact that a product ignores the order of its factors. One row of the comparison table cannot move for that reason.
| Figure | Where it comes from | How to check it yourself |
|---|---|---|
| Closing price Rs 187.4539/- | Rs 100.00/- multiplied by all 72 monthly factors | Multiplying the 72 factors in any order lands on the same figure |
| Mean 1.00 and spread 5.00 per cent | The 72 changes added, and their squared distances averaged, over 72 | Both are addition, so shuffling the rows cannot alter either |
| Lowest price Rs 96.8923/- and Rs 34.2191/- | The smallest entry on each of the two price paths | Carry Rs 100.00/- through the changes in each order and watch for the floor |
| Spreads 3.00 and 6.4031 per cent | The same spread arithmetic run on months 1 to 36 and 37 to 72 | Split the record in half and repeat the calculation on each part |
| Autocorrelations 0.2011, 0.8683 and 0.0378 | One average for the whole record, paired products over the total sum of squared deviations | State the recipe with the figure, since a second common recipe gives 0.2114 and 0.9871 |
The Nakshatra unit and its six year record are invented.
Educational material. Not advice on any investment, tax, budget or market position.
