pSfunCreate: Create distribution of probabilities spline interpolated...

Description Usage Arguments Value See Also Examples

View source: R/densities.R

Description

pSfunCreate takes a set of data and generates a distribution of probabilities function using splines to interpolate between the resulting sample points. A distribution of probabilities is a cumulative distribution function.

Usage

1
pSfunCreate(x.data, ...)

Arguments

x.data

A numeric vector containing the data.

...

All the other, optional, parameters required by density function to generate a kernel density estimation from the data.

Value

returns a function performing spline interpolation on a set of points generated from a kernel density of probabilities from the given x.data. In this case, the resulting kernel desity points are accumulated prior to the interpolation.

See Also

ffunCreate for a more generic function.

Examples

1
2
3
4
X <- log(rgamma(150,5)) # Random data generation
pfun <- pSfunCreate(X) # To create a distribution spline interpolated function
pfun(c(0.45, 1.84, 2.3))
plot(pfun, xlim=c(-0.1, 3.0))

juliosergio/spitools documentation built on May 24, 2019, 5:01 a.m.