Generates n
random numbers distributed according to the generalized
classical tempered stable (GTS) distribution.
rGTS(
n,
alphap = NULL,
alpham = NULL,
deltap = NULL,
deltam = NULL,
lambdap = NULL,
lambdam = NULL,
mu = NULL,
theta = NULL,
methodR = "AR",
k = 10000,
c = 1
)
Generates n
random numbers of the CTS distribution.
sample size (integer).
Stability parameter. A real number between 0 and 2.
Scale parameter for the right tail. A real number > 0.
Scale parameter for the left tail. A real number > 0.
Tempering parameter for the right tail. A real number > 0.
Tempering parameter for the left tail. A real number > 0.
A location parameter, any real number.
Parameters stacked as a vector.
A String. Either "TM","AR" or "SR".
integer: the level of truncation, if methodR == "SR"
. 10000
by default.
A real number. Only relevant for methodR == "AR"
.
1 by default.
theta
denotes the parameter vector (alphap, alpham, deltap,
deltam, lambdap, lambdam, mu)
. Either provide the parameters individually OR
provide theta
.
"AR" stands for the approximate Acceptance-Rejection Method and "SR" for a
truncated infinite shot noise series representation.
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 and rCTS()
.
rGTS(2,1.5,0.5,1,1,1,1,0,NULL,"SR")
rGTS(2,1.5,0.5,1,1,1,1,1,NULL,"aAR")
Run the code above in your browser using DataLab