unuran.cont-class {Runuran} | R Documentation |
Class unuran.cont
provides an interface to UNU.RAN objects for
continuous distributions.
The interface might be changed in future releases.
Do not use unnamed arguments!
[Advanced] – Continuous Distribution Object.
Create a new instance of a unuran.cont
object using
new ("unuran.cont", cdf=NULL, pdf=NULL, dpdf=NULL, islog=FALSE,
lb=NA, ub=NA, mode=NA, center=NA, area=NA, name=NA)
.
pdf
. (R function)cdf
and pdf
are given
by their logarithms (the dpdf
is then the derivative of the
logarithm). (boolean)-Inf
if unbounded from left. (numeric)Inf
if unbounded from right. (numeric)mode
is used. (numeric)pdf
; used for computing normalization
constants if required. (numeric)The user is responsible that the given informations are consistent. It depends on the chosen method which information must be given / are used.
Josef Leydold and Wolfgang H"ormann unuran@statmath.wu-wien.ac.at.
J. Leydold and W. H"ormann (2000-2007): UNU.RAN User Manual, see http://statmath.wu-wien.ac.at/unuran/.
unuran.cont.new
, unuran.new
,
unuran
.
## Create continuous distribution with given logPDF and its derivative pdf <- function (x) { -0.5*x^2 } dpdf <- function (x) { -x } distr <- new("unuran.cont", pdf=pdf, dpdf=dpdf, islog=TRUE, lb=-Inf, ub=Inf)