View source: R/eval_quantile_from_cdf.R
narrow_by_discretes | R Documentation |
When finding the inverse of the cdf at p
, and with the solution
between low
and high
, this function narrows this range based
on an intermediate discrete value, and zeroes-in on that
discrete value if it's the solution.
narrow_by_discretes(distribution, p, low, high, discrete, direction)
distribution |
A distribution having access to a cdf. |
p |
Value of the cdf to calculate inverse at. |
low , high |
Single numerics specifying the lower and upper bound to look between. |
discrete |
Numeric value indicating a discrete point to possibly
narrow the range by. Could be |
direction |
One of |
The benefit of this step when inverting a cdf is to return
the exact discrete value if p
falls within its jump discontinuity.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.