2
$\begingroup$

If you have a 100x100 grid of values and you want to report the standard deviation of an area that takes up a 20x20 portion of the grid, this is not problem. But what is the correct way to calculate the standard deviation of the 20x20 area if all the values in the 100x100 grid are themselves averages and therefore also have an associated (common) standard deviation?

I haven't dealt with such a spatial statistics problem for a while and I think I have forgotten some terminology...

$\endgroup$
2
  • $\begingroup$ Yes I don't know what you are talking about. What is the random quantity that you are computing the stanard deviation for? I don't even see what it is in the case of the 20x20 portion of the gtid where you claim there is no difficulty computing the standard deviation. $\endgroup$ Commented Sep 28, 2012 at 2:43
  • 1
    $\begingroup$ As a general policy, when you've forgotten (or don't know) terminology, I find it best to explain your question in terms that are as simple as possible. With many of my clients, my first goal is to get them to explain their question in simple, substantive terms. Then I can (often) figure out the statistics. $\endgroup$
    – Peter Flom
    Commented Sep 28, 2012 at 10:22

1 Answer 1

2
$\begingroup$

The fact that it is spacial data doesn't matter. But to correctly calculate the standard deviation of a collection of values which are, themselves, averages, you also need two other numbers for each of those values: the number of measurements which were averaged to produce each (average) value, and the standard deviation of those measurements.

So each point on the grid must have, not just one, but three numbers associated with it: the mean (the value which is the average of the measurements at that grid point), the number of measurements that were averaged to calculate that mean, and the standard deviation of those measurements. Thus, for a 20x20 grid (400 grid points) you'll have 400 averages, 400 standard deviations, and 400 sample counts.

If you have that, then you can exactly calculate the combined/composite mean and standard deviation for the whole set of 400 grid points. This web page describes how to do it, and why it works; it also includes source code in Perl and Python: http://www.burtonsys.com/climate/composite_standard_deviations.html

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.