Learn R Programming

DOBAD (version 1.0.6)

num.deriv: Numerical Differentiation

Description

Numerical derivative of one-d function defined on R.

Usage

num.deriv(ftn, var, delta = 0.001, ...)
genDoneSided(func, x, sides, method = "Richardson",
method.args = list(eps = 1e-04,
    d = 1e-04, zero.tol = sqrt(.Machine$double.eps/7e-07), r = 4,
    v = 2), ...)
hessianOneSided(func, x, sides, method = "Richardson", method.args = list(eps = 1e-04, 
     d = 1e-04, zero.tol = sqrt(.Machine$double.eps/7e-07), r = 4,                
     v = 2), ...)

Arguments

ftn, func

A (differentiable) function defined on R.

var,x

Value(s) at which to differentiate. x can be vector.

sides

of length equal to x; +1 is differentiate from above -1 from below.

method

see numDeriv package docs

method.args

see numDeriv package docs

delta

Small number defining accuracy of numeric derivative.

Value

Real number.

Details

See the 'numDeriv' package from whence the genD function and hessian function come. The versions here are one-sided adapatations of the originals from that package.