| local_stat | R Documentation | 
If bands of ursaRaster object are interpreted as observations in time, then local_stat returns some parameters for time-series analysis. This is a local operation of map algebra.
local_stat(obj, time = NULL, cover = 1e-06, smooth = FALSE, verbose = FALSE)
| obj | Object of class  | 
| time | Numeric or  | 
| cover | Numeric.  | 
| smooth | Logical. If  | 
| verbose | Logical. Value  | 
Object of class ursaRaster with bands:
| mean | Mean value in each cell across all bands of source raster. | 
| sd | Standard deviation in each cell across all bands of source raster.  Denominator is  | 
| sum | Sum value in each cell across all bands of source raster. | 
| min | Minimal value in each cell across all bands of source raster. | 
| max | Maximal value in each cell across all bands of source raster. | 
| n | Number of non- | 
| slope | Slope value in each cell across all bands of source raster. | 
| slopeS | Significance of slope value taken with a sign of slope. | 
| RSS | Resisual sum of squares. | 
| ESS | Explained sum of squares. | 
Nikita Platonov platonov@sevin.ru
Local statistics of map algebra, 
Group generics for objects of class ursaRaster.
session_grid(NULL)
set.seed(353)
session_grid(regrid(mul=1/8))
a <- ursa_dummy(nband=15)
a[a<60] <- NA
cvr <- 12
b <- local_stat(a,cover=cvr)
print(b)
c.mean <- c('<bundle> mean'=b["mean"]
           ,'local_mean'=local_mean(a,cover=cvr)
           ,'<generic> mean'=mean(a,cover=cvr))
c.max <- c('<bundle> max'=b["max"]
          ,'local_max'=local_max(a,cover=cvr)
          ,'<generic> max'=max(a,cover=cvr))
print(c.mean)
print(c.max)
cmp <- c(mean=b["mean"]-local_mean(a,cover=cvr)
        ,sd=b["sd"]-local_sd(a,cover=cvr))
print(round(cmp,12))
d <- as.list(b)
d[["slopeS"]] <- colorize(d[["slopeS"]],stretch="signif")
display(d,blank.density=20,blank.angle=c(-45,45))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.