What colour is a tree?


As much as individual, composable objects are interesting, the real understanding comes when a collection of items is analysed as a whole (or a part, if filtered).

There’s more to a collection of items than is immediately obvious - it’s not just a [1, 2, 3] list, with "array" methods for filtering and iteration: the Collection itself is an object with its own set of observable properties - many of which are summaries, in some way, of the properties in the items in the collection.

These summaries describe some aggregate quality of the collection, and - ideally - an indication of the variance, or confidence intervals, for that value within the collection.

For example, consider this question:
What colour is a tree?

When you look at a tree, what you’re seeing is a collection of trees over time. Your eye analyses the light arriving from the tree, and your brain tries to summarise the wavelengths that it’s seeing. The colours might cycle over time, as day and night pass, and they might cycle over longer periods, as seasons pass.

If you look around, you’ll see trees with different coloured leaves, depending on their genotype and phenotype. This is also a collection of trees, but distributed over space rather than time. The further away you look, the greater likelihood that the colour of a tree will be more different from the closest trees - the variance within the collection will increase.

So: observed properties of a collection can vary over time, or over space, depending on the conditions in which they’re found and the conditions of observation.

The observed colour of a tree - or a collection of trees - is a function with many inputs and one output: the wavelength(s) of light that leave the tree and enter your eye (or some other detector).

For any collection of items, a function can be written that describes one of their properties under certain conditions.

For example, the value(s) that this function outputs might be the mean (average) and standard deviation of a series of measurements over time, or it may group those values into buckets (the sort of data that might be displayed as a bar chart).

This is how we understand the world, and why we like collecting and classifying objects. To be able to understand the shared properties of items in a group, and differences from items in a different group, is to begin to understand them. Once we group items together, we can start to predict how they might behave.