Learn R Programming

fda (version 1.2.3)

expect.phi: Expectatation of basis functions

Description

Computes expectations of basis functions with respect to a density by numerical integration using Romberg integration

Usage

normint.phi(basisobj, cvec, JMAX=15, EPS=1e-7) 
normden.phi(basisobj, cvec, JMAX=15, EPS=1e-7) 
expect.phi(basisobj, cvec, nderiv=0, rng=rangeval,
                     JMAX=15, EPS=1e-7) 
expectden.phi(basisobj, cvec, Cval=1, nderiv=0, rng=rangeval,
                     JMAX=15, EPS=1e-7)
expectden.phiphit(basisobj, cvec, Cval=1, nderiv1=0,
                 nderiv2=0, rng=rangeval, JMAX=15, EPS=1e-7)

Arguments

basisobj
a basis function object
cvec
coefficient vector defining density, of length NBASIS
Cval
normalizing constant defining density
nderiv, nderiv1, nderiv2
order of derivative required for basis function expectation
rng
a vector of length 2 giving the interval over which the integration is to take place
JMAX
maximum number of allowable iterations
EPS
convergence criterion for relative stop

Value

  • A vector SS of length NBASIS of integrals of functions.

Details

normint.phi computes integrals of p(x) = exp phi'(x) normdel.phi computes integrals of p(x) = exp phi"(x) expect.phi computes expectations of basis functions with respect to intensity p(x) <- exp t(c)*phi(x)

expectden.phi computes expectations of basis functions with respect to density

p(x) <- exp(t(c)*phi(x))/Cval

expectden.phiphit computes expectations of cross product of basis functions with respect to density

p(x) <- exp(t(c)*phi(x))/Cval

See Also

plot.basisfd,