Description Usage Arguments Details Value Author(s) Examples
Function from this global.\emph{FUN} list returns requred statistics FUN for the whole image.
1 2 3 4 5 6 7 8 9  | 
x | 
 Object of class   | 
ursa | 
 Logical. The class of returned value. If   | 
... | 
 Arguments in function   | 
For any function global.\emph{FUN}, if argument na.rm is not in ..., then \emph{FUN} is called with forced na.rm=TRUE.
global_range\emph{list of arguments} is implemented as c(global_min(\emph{list of arguments}), global_max(\emph{list of arguments})) with the same list of arguments.
Alternative method to get global statistics is function applying directly to the raster value. For example, sd(ursa_value(x,na.rm=TRUE)). This way is also appropriate for missing global functions: for example, var(ursa_value(x,na.rm=TRUE)).
If ursa=FALSE then numeric.
If ursa=TRUE then object of class ursaRaster.
Nikita Platonov platonov@sevin.ru
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17  | session_grid(NULL)
a <- ursa_dummy(2,min=-40,max=80)
a[a<0] <- NA
print(a)
a.mean <- global_mean(a)
a.sd <- global_sd(a)
a.sum <- global_sum(a)
a.min <- global_min(a)
a.max <- global_max(a)
a.median <- global_median(a)
print(c(mean=a.mean,sd=a.sd,sum=a.sum,min=a.min,max=a.max,median=a.median))
v.max <- max(ursa_value(a),na.rm=TRUE)
print(c('global_max()'=a.max,'max(ursa_value())'=v.max,dif=a.max-v.max))
r.max <- global_max(a,ursa=TRUE)
print(r.max)
b <- c(a,'appended scalar value'=a.max)
print(b)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.