In this vignette, we will show how to generate realistic datasets. For this example, the data will be simulated based on the powerconsumption
dataset provides in the package.
First, we need to estimate the mean, covariance and noise of the real dataset. Pay attention that these functions may take some time to execute.
mu <- learn_mean(powerconsumption)
cov <- learn_covariance(powerconsumption)
noise <- learn_noise(powerconsumption)
Then, we can generate some curves using the previous estimated parameters.
X <- generate_data(10, 100, mu, cov, noise, exp(-5.5), NULL, 0.2, 1)
Now, we will (visually) compare true data with a simulated realization. The true data from the powerconsumption dataset is plotted in blue, while a generated curve is plotted in red.
X <- generate_data(1, 1440, mu, cov, noise, exp(-5.5), NULL, 0.2, 1)