spline_funs: Helpful closures

Description Usage Arguments Functions Examples

Description

Create linear approximation or spline approximation functions from a given set of points.

Usage

1
2
3
4
5
spline_funs(clicks, xrange, spar = 0.5)

linear_funs(clicks, xrange)

mean_funs(upper, lower, meth)

Arguments

clicks

Clicked data

xrange

Vector of length 2 giving the minimum and maximum domain values for the spline function.

spar

Numeric. Value of the smoothing parameter (between 0-1) to be passed to smooth.spline().

upper

Data frame. The upper bound of points for the cdf

lower

Data frame. The lower bound of points for the cdf

meth

Character. Approximation method. either "splines" for smooth.spline() or "linear" for approxfun()

Functions

Examples

1
2
3
4
## Not run: 
splinefuns(clicks)(seq(xmin, xmax, length.out = 100))

## End(Not run)

sctyner/dprocsim documentation built on June 30, 2019, 11:51 a.m.