Skip to contents

The interval is [center - width/2, center + width/2].

Usage

DensProbC(grid, density, center, width)

Arguments

grid, density

the density on a strictly increasing grid.

center, width

the interval centre and total width.

Value

list(probability, center, width).

References

Morin, D. J. (2016). Probability: For the Enthusiastic Beginner. Createspace. Eq (4.4).

Examples

g <- seq(-6, 6, length.out = 1201); DensProbC(g, stats::dnorm(g), 0, 2)$probability
#> [1] 0.6826848