trapez | R Documentation |
This is a numerical integration of y with respect to x by the trapezoidal method on linear scale.
trapez(x, y, cum = FALSE, na.rm = FALSE)
x |
The vector to integrate y with respect to (typically TIME to get area under the curve). |
y |
The variable to integrate. |
cum |
Return the cumulative trapezoidal area under the curve? If false (default) a single number is returned. If true, a vector is returned. Notice, the vector is one element shorter than x and y. |
na.rm |
Remove indexes in x and y wherever x or y are NA. |
a numeric
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.