gammaBlur: Multichannel Gamma density blur

Description Usage Arguments Details Value See Also Examples

View source: R/makeFunctions.R

Description

Create blur of the regular smooth type generated from Gamma densities

Usage

1
gammaBlur(n, shape, scale)

Arguments

n

An integer specifying the number of observations in each channel.

shape

A numeric vector of length m where each element specifies the shape parameter for the Gamma density used to blur each channel.

scale

A numeric vector of length m where each element specifies the scale parameter for the Gamma density used to blur each channel.

Details

Function creates a matrix of dimension n by m which contains a normalised (unit energy in each column) set of blur functions of regular smooth type, generated by a Gamma density. These Gamma densities are generated using the dgamma base R function and then normalised to have unit energy.

Value

A numeric n by m matrix of normalised Gamma blur.

See Also

dgamma for details of the Gamma density

boxcarBlur, blurSignal

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
n <- 1024
m <- 3
shape <- seq(from = 0.5, to = 1, length = m)
scale <- rep(0.25,m)

# Plot the smooth (gamma) blur
x <- (1:n)/n
blurMat <- gammaBlur(n, shape, scale)
matplot(x, blurMat, type = 'l', main = paste('Set of Gamma', m,'Gamma blur densities.'))

# Plot a LIDAR signal and its multichannel smooth blurred version
signal <- makeLIDAR(n)
matplot(x, signal, type = 'l', main = 'LIDAR test signal')
blurredSignal <- blurSignal(signal, blurMat)
matplot(x, blurredSignal, type = 'l', main = 'Smooth blurred LIDAR test signals')

mwaved documentation built on July 13, 2017, 5:03 p.m.