[R] Inverting integration

David Scott d.scott at auckland.ac.nz
Mon Nov 10 03:29:09 CET 2008


On Sun, 9 Nov 2008, Yan (Daniel) Zhao wrote:

> Suppose I have a function f(x) (say, f(x)=exp(sin(x)),  how do I find the
> number y such that the integral of f(x) on the interval of (-infinity, y) is
> equal to a specified number, say, .8?
>
> Thanks,
> Yan
>

See ?uniroot

David Scott

_________________________________________________________________
David Scott	Department of Statistics, Tamaki Campus
 		The University of Auckland, PB 92019
 		Auckland 1142,    NEW ZEALAND
Phone: +64 9 373 7599 ext 86830		Fax: +64 9 373 7000
Email:	d.scott at auckland.ac.nz

Graduate Officer, Department of Statistics
Director of Consulting, Department of Statistics



More information about the R-help mailing list