Learn R Programming

dsp (version 1.2.0)

simUnivariate: Generate univariate signals of different type

Description

Using code from the archived wmtsa package

Usage

simUnivariate(name, n = 1024, snr = Inf)

Value

A numeric vector the same length as n.

Arguments

name

character string of name of the test wavelet signal to be generated; one of "dirac", "kronecker", "heavisine", "bumps", "blocks", "doppler", "ramp", "cusp", "crease", "sing", "hisine", "losine", "linchirp", "twochirp", "quadchirp", "mishmash1", "mishmash2", "mishmash3", "levelshift", "jumpsine", "gauss", "patches", "linear", "quadratic", "cubic";

n

length of the series; defaults to 1024 points; increasing n infills the time series

snr

desired signal-to-noise ratio; default Inf corresponds to 0 noise

Examples

Run this code
nms <- c("blocks", "linchirp", "mishmash1", "bumps")
z <- lapply(nms, simUnivariate)

Run the code above in your browser using DataLab