Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

int.simpson

Simpson integration


Description

Computes the integral of fdataobj$data with respect to fdataobj$argvals using simpson or trapezoid rule integration.

Usage

int.simpson(fdataobj, method = NULL)

int.simpson2(x, y, equi = TRUE, method = NULL)

Arguments

fdataobj

fdata objtect.

method

Method for numerical integration, see details.

x

Sorted vector of x-axis values: argvals.

y

Vector of y-axis values.

equi

=TRUE, the observed points on each curve are equally spaced (by default).

Details

Posible values for method are:

  • "TRAPZ": Trapezoid rule integration.

  • "CSR": Composite Simpson's rule integration.

  • "ESR": Extended Simpson's rule integration.

If method=NULL (default), the value of par.fda.usc$int.method is used.

Author(s)

Manuel Febrero-Bande, Manuel Oviedo de la Fuente manuel.oviedo@usc.es

See Also

See also integrate.

Examples

## Not run: 
x<-seq(0,2*pi,length=1001)
fx<-fdata(sin(x)/sqrt(pi),x)
fx0<-fdata(rep(0,length(x)),x)
int.simpson(fx0)
int.simpson(fx)

## End(Not run)

fda.usc

Functional Data Analysis and Utilities for Statistical Computing

v2.0.2
GPL-2
Authors
Manuel Febrero Bande [aut], Manuel Oviedo de la Fuente [aut, cre], Pedro Galeano [ctb], Alicia Nieto [ctb], Eduardo Garcia-Portugues [ctb]
Initial release
2020-02-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.