Learn R Programming

empirical (version 0.2.0)

univariate: Nonparametric Univariate Probability Distributions

Description

Empirical univariate probability density functions, empirical univariate cumulative distribution functions and empirical univariate quantile functions. Refer to the vignette for better examples.

Usage

epdfuv (x, derandomize=TRUE, preserve="mean",
    drp, nhood, bind=TRUE, randomize=TRUE, w=NA)
ecdfuv (x, derandomize=TRUE, preserve="mean",
    drp, nhood, bind=TRUE, randomize=TRUE, w=NA)
ecdfuv.inverse (x, derandomize=TRUE, preserve="mean",
    drp, nhood, bind=TRUE, randomize=TRUE, w=NA)

Arguments

x

A vector of data points.

derandomize

If true, smooth the data points.

preserve

Either "mean" or "range". If derandomize and mean (the default), preserve the mean and variance. If derandomize and range, preserve the range.

drp

A smoothness (derandomization) parameter. Refer to the vignette.

nhood

A neighborhood size parameter. Refer to the vignette.

bind

If true, add an extra two data points.

randomize

If there a duplicated values, add a small amount of random variation.

w

A vector of weights.

Value

These functions return functions.

See Also

epdfmv, ecdfmv, epdfc, ecdfc, ecdfc.inverse, epdfuv.f, ecdfuv.f, ecdfuv.f.inverse

Examples

Run this code
# NOT RUN {
#construct an empirical univariate probability density function
#and then evaluate it
data (trees)
attach (trees)
epdfuv.f = epdfuv (Height)
epdfuv.f (80)
# }

Run the code above in your browser using DataLab