Skip to contents

This function is used to generate simulated degradation data.

Usage

sim_dat(
  group = 5,
  t = 1:100,
  para = c(2, 3),
  process = "Wiener",
  type = "classical",
  s = NULL,
  rel = NULL
)

Arguments

group

The number of groups of products

t

time.

para

parameters of a certain model.

process

Wiener, Gamma or Inverse Gaussian process.

type

classical in default.

s

stress.

rel

relationship.

Value

Return a list containing simulated data at different time points for each group. The output is a list. The first part of the list is the amount of degradation of the simulated data, and the second part is the increment of its degradation

Examples

dat <- sim_dat(
  group = 5, t = 1:200, para = c(2, 3),
  process = "Wiener", type = "classical",
  s = NULL, rel = NULL
)
str(dat)
#> List of 1
#>  $ :'data.frame':	200 obs. of  6 variables:
#>   ..$ Time: num [1:200] 0 1 2 3 4 5 6 7 8 9 ...
#>   ..$ 1   : num [1:200] 0 2.56 5.29 9.1 7.43 ...
#>   ..$ 2   : num [1:200] 0 -0.093 3.804 5.439 8.098 ...
#>   ..$ 3   : num [1:200] 0 -0.883 -1.753 2.458 4.049 ...
#>   ..$ 4   : num [1:200] 0 1.73 7.65 6.17 6.19 ...
#>   ..$ 5   : num [1:200] 0 6.97 13.33 16.73 23.38 ...