DeregulariseByAlpha {fdadensity} | R Documentation |
Function to deregularise densities to have (smaller) minimum value
Description
If possible, deregularises the input density y
to have minimum density value is alpha
. See details.
Usage
DeregulariseByAlpha(x, y, alpha = 0)
Arguments
x |
support of the density |
y |
values of the density |
alpha |
scalar to deregularise with (default = 0) - this will be the minimum value of the deregularised density, unless |
Details
If min(y) <= alpha
, or y
is the uniform distribution, no deregularisation is performed and y
is returned. If min(y)*diff(range(x)) > 1
,
the deregularisation is not possible and an error is thrown. Otherwise, the deregularised density in an inverse manner to RegulariseByAlpha
.
Value
dens density values on x
See Also
Examples
x = seq(0,1,length.out=122)
y = seq(0.1,1.9,length.out=122)
z = DeregulariseByAlpha(x=x, y=y, alpha = 0)
[Package fdadensity version 0.1.2 Index]