Generates n
random numbers distributed according
of the tempered stable subordinator distribution.
rTSS(
n,
alpha = NULL,
delta = NULL,
lambda = NULL,
theta = NULL,
methodR = "TM",
k = 10000
)
Generates n
random numbers.
sample size (integer).
Stability parameter. A real number between 0 and 1.
Scale parameter. A real number > 0.
Tempering parameter. A real number > 0.
Parameters stacked as a vector.
A String. Either "TM", "AR" or "SR".
integer: the level of truncation, if methodR == "SR"
. 10000
by default.
theta
denotes the parameter vector (alpha, delta, lambda)
.
Either provide the parameters alpha
, delta
, lambda
individually OR provide theta
.
"AR" stands for the Acceptance-Rejection Method and "SR" for a truncated
infinite shot noise series representation. "TM" stands for Two Methods as
two different methods are used depending on which will be faster. In this
method the function copula::retstable()
is called. "TM" is the standard
method used.
It is recommended to check the generated random numbers once for each distribution using the density function. If the random numbers are shifted, e.g. for the method "SR", it may be worthwhile to increase k.
For more details, see references.
Massing, T. (2023), 'Parametric Estimation of Tempered Stable Laws'
Kawai, R & Masuda, H (2011), 'On simulation of tempered stable random variates' tools:::Rd_expr_doi("10.1016/j.cam.2010.12.014")
Hofert, M (2011), 'Sampling Exponentially Tilted Stable Distributions' tools:::Rd_expr_doi("10.1145/2043635.2043638")
copula::retstable()
as "TM" uses this function.
rTSS(100,0.5,1,1)
rTSS(100,0.5,1,1,NULL,"SR",50)
Run the code above in your browser using DataLab