Learn R Programming

amber (version 1.0.3)

intFun.grid.significance: Set significant differences to NA

Description

This function sets all values that are equal or less than 0.05 to NA. Applied to a raster that shows the p-values of a significance test, the function sets all statistically significant differences to NA at the 5 percent level.

Usage

intFun.grid.significance(x)

Arguments

x

A raster object

Value

A raster object

Examples

Run this code
# NOT RUN {
library(raster)
# make some data
data <- runif(100,0,1)
data <- matrix(data, ncol=10)
data <- raster::raster(data)
# repeat raster stack 10 times
data <- intFun.grid.significance(data)
plot(data); text(data, digits=2)

# }

Run the code above in your browser using DataLab