| UnivarMixingDistribution-class {distr} | R Documentation |
Class "UnivarMixingDistribution"
Description
UnivarMixingDistribution-class is a class to formalize
univariate mixing distributions; it is a subclass to
class UnivariateDistribution.
Objects from the Class
Objects can be created by calls of the form
new("UnivarMixingDistribution", ...).
More frequently they are created via the generating function
UnivarMixingDistribution.
Slots
mixCoeffObject of class
"numeric": a vector of probabilities for the mixing components.mixDistrObject of class
"UnivarDistrList": a list of univariate distributions containing the mixing components; must be of same length asmixCoeff.imgObject of class
"Reals": the space of the image of this distribution which has dimension 1 and the name "Real Space"paramObject of class
"Parameter": the parameter of this distribution, having only the slot name "Parameter of a discrete distribution"rObject of class
"function": generates random numbersdfixed to
NULLpObject of class
"function": cumulative distribution functionqObject of class
"function": quantile functionsupportnumeric vector — the union of all support slots of components, if existing
gaps(numeric) matrix or
NULL; the mergedgapsslots of all components, if existing (else NULL).withArithlogical: used internally to issue warnings as to interpretation of arithmetics
.withSimlogical: used internally to issue warnings as to accuracy
.logExactlogical: used internally to flag the case where there are explicit formulae for the log version of density, cdf, and quantile function
.lowerExactlogical: used internally to flag the case where there are explicit formulae for the lower tail version of cdf and quantile function
Symmetryobject of class
"DistributionSymmetry"; used internally to avoid unnecessary calculations.
Extends
Class "UnivariateDistribution"
class "Distribution" by class "UnivariateDistribution".
Methods
- show
signature(object = "UnivarMixingDistribution")prints the object- mixCoeff<-
signature(object = "UnivarMixingDistribution")replaces the corresponding slot- mixCoeff
signature(object = "UnivarMixingDistribution")returns the corresponding slot- mixDistr<-
signature(object = "UnivarMixingDistribution")replaces the corresponding slot- mixDistr
signature(object = "UnivarMixingDistribution")returns the corresponding slot- support
signature(object = "UnivarMixingDistribution")returns the corresponding slot- gaps
signature(object = "UnivarMixingDistribution")returns the corresponding slot- .logExact
signature(object = "Distribution"): returns slot.logExactif existing; else tries to convert the object to a newer version of its class byconv2NewVersionand returns the corresponding slot of the converted object.- .lowerExact
signature(object = "Distribution"): returns slot.lowerExactif existing; else tries to convert the object to a newer version of its class byconv2NewVersionand returns the corresponding slot of the converted object.- Symmetry
returns slot
Symmetryif existing; else tries to convert the object to a newer version of its class byconv2NewVersionand returns the corresponding slot of the converted object.
Author(s)
Peter Ruckdeschel peter.ruckdeschel@uni-oldenburg.de
See Also
Parameter-class,
UnivariateDistribution-class,
LatticeDistribution-class,
AbscontDistribution-class,
simplifyD,
flat.mix
Examples
mylist <- UnivarMixingDistribution(Binom(3,.3), Dirac(2), Norm(),
mixCoeff=c(1/4,1/5,11/20))
mylist2 <- UnivarMixingDistribution(Binom(3,.3), mylist,
mixCoeff=c(.3,.7))
mylist2
p(mylist)(0.3)
mixDistr(mylist2)