resid.median {RSAGA} | R Documentation |
These functions use the median and other quantiles to
describe the difference between a grid value and its neighborhood.
They are designed for use with focal.function
.
resid.median(x) resid.minmedmax(x) resid.quartiles(x) resid.quantile(x, probs)
x |
a square matrix with the grid data from the moving window,
possibly containing NA values |
probs |
numeric vector of probabilities in [0,1] to be passed
to quantile |
These functions are designed for being called by
focal.function
, which repeatedly passes the contents
of a square or circular moving window to these functions.
The resid.median
function rests the value of the central grid cell
from the median of the whole moving window. Thus, in terms of topography,
a positive residual median indicates that this grid cell stands out
compared to its surroundings. resid.quantile
gives more flexibility
in designing such residual attributes.
If x
is provided, a numeric vector of length 1 (resid.median
),
3 (resid.minmedmax
and resid.quartiles
), or
length(probs)
(resid.quantile
).
If x
is missing, a character vector of same length giving suggested
variable (or file) names, such as "rmed"
. See focal.function
for details.
Alexander Brenning
focal.function
, quantile
,
median
, centervalue