View source: R/helper_functions.R
simUnivariate | R Documentation |
Builds upon the make.signal()
function (originally in the wmtsa
package)
to include Gaussian noise with a user-specified root-signal-to-noise ratio.
simUnivariate(signalName = "bumps", T = 200, RSNR = 10, include_plot = TRUE)
signalName |
string matching the "name" argument in the |
T |
number of points |
RSNR |
root-signal-to-noise ratio |
include_plot |
logical; if TRUE, include a plot of the simulated data and the true curve |
a list containing
the simulated function y
the true function y_true
the true observation standard devation sigma_true
The root-signal-to-noise ratio is defined as RSNR = [sd of true function]/[sd of noise].
sims = simUnivariate() # default simulations
names(sims) # variables included in the list
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.