# Why do we treat a value at each location as a random variable?

Apology if my question is very simple to you (I am very new to geostatistic). Suppose that X is a random variable (e.g., the concentration of the Zinc at a specific area). Now, we measure the concentration of the Zinc at several locations (say 10). As I understand the spatial random filed is defined when we assume that the value of the X at each location is treated as a random variable! This confuses me. Why? because at each location we measure the concentration of the Zinc once. So, how it can be a random variable. If I have only one realization for each location, how can I find the mean and variance? What I understand is that X is a random variable with 10 values (as we have 10 locations). But not the value of X at each location can be treated as a random variable. Am I missing something? any clarification, please? Here is the link (second paragraph)

• Before you collect the data, if your 10 locations were selected at random, the value of X at any one of those locations would be considered random (which implies there is uncertainty about its value). After you collect the data, the value of X at any one of those locations is obviously no longer random - it is known with 100% certainty. – Isabella Ghement Aug 13 '19 at 17:35
• @Isabella Although that's a natural approach, often termed "sampling uncertainty," it's not the approach taken in geostatistics. Geostatistics adopts a probability model for the data, assuming they are a realization of an ergodic stochastic process (a "random field"). One term that has been used is "model uncertainty." What this achieves is a fairly powerful method to predict values at unobserved locations. The resulting algorithm ("kriging") does not treat any of the locations as random. – whuber Aug 14 '19 at 12:46

I think you are confusing the ideas of a random variable, $$X$$, and a collection of random variables, more properly known as a random process, $$(X_{t})_{t \in T}$$. In this notation, $$T$$ is some index set and $$t$$ is some value from this index set.

A common example of a random process is a random walk in one dimension. I'll give you a verbal description of a concrete example and then translate that into mathematical notation. I will then show that this example can be generalized to the example you gave in your question.

We have someone standing at a particular initial point; for every second afterwards the person either moves forward one step with probability $$\frac{1}{2}$$ or backward with probability $$\frac{1}{2}$$. Each step taken is a random variable (here, these specific random variables are called Rademacher or symmetric Bernoulli random variables), and the location of our random walker at any second is the sum of the person's initial location and the forward and backward steps taken up to that moment. But a sum of random variables is itself a random variable, so the walker's position at any second is also a random variable.

Translating this into our notation, we have $$T = \mathbb{N} = \{0, 1, 2, 3, \dots \}$$. We will denote our walker's initial location by the random variable $$Z_{0}$$ - this random variable may have some distribution over specific points on the line our walker is on, but the details aren't important for this explanation, so we may just as well treat $$Z_{0}$$ as a constant. Each step taken at any second $$t\geq 1$$ will be denoted by the random variable $$Z_{t}$$. Now for times $$t \geq 1$$, $$Z_{t}$$ has only two possible values, $$-1$$ or $$+1$$, which correspond to one step forward or one step backward. The probabilities are equal, that is $$P(Z_{t} = -1) = P(Z_{t} = +1) = \frac{1}{2}$$. And finally, as mentioned above, our walker's location at any time $$t$$, denoted by $$X_{t}$$, can be found by taking the sum of the walker's initial location and all steps taken so far: $$X_{t} = \sum_{i = 0}^{t}Z_{i}$$. This means that your random walk is an infinite sequence of random variables, $$(X_{0}, X_{1}, X_{2}, X_{3}, \dots)$$. An important point to note here is that even though the step $$Z_{t}$$ taken at any time $$t$$ is independent of a step $$Z_{s}$$ taken at any other time $$s \leq t$$, the value of the location $$X_{t}$$ at time $$t$$ is not independent of the values of $$X_{s}$$ for other times $$s \leq t$$.

Now how does this relate to your example of Zinc concentrations? Well, your example is still a random process. Based on your description, we should take our index set to be the plane, i.e. $$T = \mathbb{R}^2$$ (technically, some compact subset of the plane, but I digress). This type of random process is called a random field. You can think of it like this: you have a map of the region where you will be looking for Zinc deposits. At each point on the map you have a random variable whose distribution somehow captures the probability of finding Zinc at that point. So your entire map is associated with a collection of random variables $$(X_{s})_{s \in \mathbb{R}^{2}}$$ - that is your random field for this example. Unlike the random walk example earlier, this collection may be much more complicated - the distributions of each $$X_{s}$$ may be vastly different from each other; for instance, different types of soil or different environments may be associated with different probabilities of encountering a Zinc deposit. And it is likely that there is some complicated covariance structure relating the variables together through conditional relationships. For example, if you found Zinc at some specific point $$s_{0}$$, then it may be more likely that you will also find Zinc at nearby points, say some points $$s'$$ within some distance $$\delta$$ of $$s_{0}$$. So measuring $$X_{s_{0}}$$ could give you information about all the random variables $$X_{s'}$$ for $$|s_{0} - s'| \leq \delta$$. This is actually similar to the lack of independence of the $$X_{t}$$ random variables in our earlier random walk example.

To try to clarify another point of confusion you seem to have, when you talk about sampling $$10$$ points on your map, you are actually taking $$10$$ of these random variables from the entire collection $$(X_{s})_{s \in \mathbb{R}^{2}}$$ and observing an outcome, i.e. sampling from the $$10$$ distributions, of those $$10$$ random variables. Part of the randomness involved may also describe your potential failure to detect a Zinc deposit at some point $$s$$ even though there actually is a Zinc deposit at that location. The entire collection $$(X_{s})_{s \in \mathbb{R}^{2}}$$ is an uncountably infinite set of random variables, as mentioned in the spatial data analysis summary notes in your above link.

And as mentioned in the comment by Isabella Ghement, all these descriptions of quantities as random variables obviously only apply before you actually go out and make an observation. You probably want to take a Bayesian interpretation here, where the probability refers to your lack of knowledge about the location of Zinc deposits. With this interpretation, the distributions of all the random variables reflect some belief about finding a Zinc deposit at any point on the map. Once you actually actually go out and measure the amount of Zinc at any point, you have removed your uncertainty about whether there is or is not Zinc at that point.

• Amaizing help. Thank you so much. – Mary Aug 14 '19 at 11:29
• (+1) It is unnecessary to adopt a Bayesian point of view: classical geostatistics views this problem as one of predicting linear functionals of the random field conditioned on the observations. – whuber Aug 14 '19 at 12:48
• (+1) This is such an elegant and eloquent answer, Don! – Isabella Ghement Aug 14 '19 at 14:38