1
|
/* need to ensure that the aggregation boxes are consistent across the whole set of layers
|
2
|
/* so might need a setwindow here to enforce the correct location
|
3
|
|
4
|
/* Question about 1km Behrman version - should that be projected from 30" stats, or
|
5
|
/* should data be projected to Behrman and aggregated over 1km cell. Far from the equator
|
6
|
/* these will give quite different results
|
7
|
|
8
|
/* elevation - derive mean, min, max, std. dev, skew
|
9
|
elev_mean = aggregate(srtmv41_smth, 10, mean)
|
10
|
elev_min = aggregate(srtmv41_smth, 10, min)
|
11
|
elev_max = aggregate(srtmv41_smth, 10, max)
|
12
|
elev_range = elev_max - elev_min
|
13
|
/* stupid arc doesn't have a standard deviation function for aggregation
|
14
|
elev_sd = sqrt(aggregate(sqr(srtmv41_smth - elev_mean), 10, sum) / 100)
|
15
|
|
16
|
|
17
|
/* slope - just mean and standard deviation
|
18
|
slopedeg_mean = aggregate(slopedeg, 10, mean)
|
19
|
slopedeg_sd = sqrt(aggregate(sqr(slopdeg - slopedeg_mean), 10, sum) / 100)
|
20
|
|
21
|
/* wetness index - mean and standard deviation
|
22
|
/* twi not done yet
|