distr (version 2.4)

Truncate-methods: Methods for function Truncate in Package `distr'

Description

Truncate-methods

Usage

Truncate(object, ...)
## S3 method for class 'AbscontDistribution':
Truncate(object, lower = -Inf, upper = Inf)
## S3 method for class 'DiscreteDistribution':
Truncate(object, lower= -Inf, upper = Inf)
## S3 method for class 'LatticeDistribution':
Truncate(object, lower= -Inf, upper = Inf)
## S3 method for class 'UnivarLebDecDistribution':
Truncate(object, lower = -Inf, upper = Inf, 
                    withSimplify = getdistrOption("simplifyD"))

Arguments

object
distribution object
...
not yet used; takes up lower, upper, withSimplify.
lower
numeric; lower truncation point
upper
numeric; upper truncation point
withSimplify
logical; is result to be piped through a call to simplifyD?

Value

  • the corresponding distribution of the truncated random variable

concept

truncation

See Also

Huberize, Minimum

Examples

Run this code
plot(Truncate(Norm(),lower=-1,upper=2))
TN <- Truncate(Norm(),lower=15,upper=15.7) ### remarkably right!
plot(TN)
r(TN)(30)
TNG <- Truncate(Geom(prob=0.05),lower=325,upper=329) ### remarkably right!
plot(TNG)

Run the code above in your browser using DataCamp Workspace