Learn R Programming

rv (version 0.949)

rvinci: Is a value inside a confidence interval?

Description

rvinci returns TRUE iff a given value is inside a given interval.

Usage

rvinci(obj, x, interval=0.95, one.sided=FALSE, left=FALSE)

Arguments

obj
a random variable.
x
a numeric object.
interval
a number between 0 and 1.
one.sided
logical. Is the interval one-sided?
left
logical. Is the one-sided interval on the left?

Value

  • A logical vector.

Details

Returns TRUE if x (a number) is in the 100*interval% interval of the random variable obj.

References

Kerman, Jouni and Gelman, Andrew. Manipulating and Summarizing Posterior Simulations Using Random Variable Objects. Technical report, Columbia University, New York.

Examples

Run this code
#

Run the code above in your browser using DataLab