log-concave: The Log-concave Distribution.

Description Usage Arguments Value References See Also Examples

Description

Density and dstribution function for a log-concave distribution.

Usage

1
2
dlcd(x, lcd, log = FALSE)
plcd(q, lcd, lower.tail = TRUE, log.p = FALSE)

Arguments

x, q

vector of quantiles.

lcd

an object of class lcd.

log, log.p

logical. If TRUE, the log density or log probability values are to be returned.

lower.tail

logical. If TRUE (default), probabilities are p[X <= q]; if otherwise, p[X > q].

Value

dlcd gives the density values, and plcd gives the distribution function values.

References

Liu, Y. and Wang, Y. (2018). A Fast Algorithm for Univariate Log-concave Density Estimation. Australia & New Zealand Journal of Statistics (To appear).

See Also

cnmlcd, lcd.

Examples

1
2
3
4
5
6
x = rnorm(1000)
r = cnmlcd(x)
dlcd(-4:4, r$lcd)
dlcd(-4:4, r$lcd, log=TRUE)
plcd(-4:4, r$lcd)
plcd(-4:4, r$lcd, lower.tail = FALSE)

cnmlcd documentation built on May 1, 2019, 10:55 p.m.

Related to log-concave in cnmlcd...