smoothconv: Smoothening using convolution with a circular kernel

Description Usage Arguments Value Author(s) Examples

View source: R/smoothconv.R

Description

The input field is convolved with a circular kernel with equal weights. Takes into account missing values.

Usage

1
smoothconv(z, nas)

Arguments

z

matrix with the input field to smoothen, with dimensions c(ns, ns)

nas

the smoothing kernel uses a radius (ns/nas)/2

Value

The smoothened field.

Author(s)

Jost von Hardenberg, j.vonhardenberg@isac.cnr.it

Examples

1
2
3
4
5
z <- rnorm(64 * 64)
dim(z) <- c(64, 64)
zs <- smoothconv(z, 8)
sd(zs)
# [1] 0.07910996

rainfarmr documentation built on May 1, 2019, 8:02 p.m.