TS_sample: Time Series Sample-Generator

TS_sampleR Documentation

Time Series Sample-Generator

Description

Time Series Sample-Generator

Usage

TS_sample(
  TS_key = "rnorm",
  N = 500,
  nr_samples = 1,
  ...,
  .seed = NULL,
  .kind_vstr_list = NULL
)

Arguments

TS_key

A key, i.e. a character, corresponding to an element in TS_families. Default value rnorm, i.e. "White Noise Gaussian".

N

The desired length of the time series. Default value 500.

nr_samples

The desired number of independent samples to be produced. The default value 1 gives a single sample, which might be preferable for an initial investigation that includes many different bandwidths and looks at a wide range of points. For pointwise confidence bands it might be preferable to use at least 100 for this argument.

...

dotsMethods-strategy for feeding parameters to the function (identified by TS_key) that generates the time series.

.seed

Use this to enable reproducible results. Default value NULL (it will be generated and recorded in the code).

.kind_vstr_list

This can be used to create a list with the values for kind, normal.kind and vstr. (See the help-page of Random for details about these three arguments.) Note that the default value NULL will imply that the function set_seed will be used to create the required list based on the present settings.

Details

This function will create one or more time series based on the "keys" stored in TS_families, with emphasis on also storing the required arguments needed in order to reproduce it later on.

Value

This function returns a list with the following four parts:

TS

A 3-dimensional array with the resulting time series, generated according to the specified arguments. The array contains three dimensions in order to have a unified solution for univariate and multivariate solutions. The first dimension reflects the number of samples, as given by nr_samples. The second dimension reflects the length of the samples, as given by N. The third dimension reflects the number of variables in the time series, which is decided by TS_key and the arguments given to ...

TS_data

Additional details used by TS_LG_object when the data is saved to disk.

spy_report

An environment that contains all the arguments that was used for the present computation.

seed_vec

This part reflects that the internal workings of the code creates a vector of seeds (based on .seed) that then can be used to reproduce an individual series later on. This is of course only of interest when nr_samples is larger than one, and we for some reason later on would like to do an in depth analysis of one of the resulting time series.


LAJordanger/localgaussSpec documentation built on May 6, 2023, 4:31 a.m.