It seems you want to integrate a function. Try ?integrate
You can do the math yourself if the function is simple, like sin(x). Otherwise I suspect you could combine integrate with `deriv', although you will slow down the calculations somehow (just a guess). HTH Giovanni > Date: Thu, 13 Nov 2003 21:37:46 -0500 > From: Greg Trafton <[EMAIL PROTECTED]> > Sender: [EMAIL PROTECTED] > Precedence: list > User-Agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.2 (darwin) > > Hi, All. I have a function I want to know the plotted length of. is it > possible to calculate the length of the function (e.g., arc length)? > > for example, if I want to know the length of the line of > sin(x) from -pi to pi, how can I do that in R? > > thanks! > greg > > ______________________________________________ > [EMAIL PROTECTED] mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-help > > -- __________________________________________________ [ ] [ Giovanni Petris [EMAIL PROTECTED] ] [ Department of Mathematical Sciences ] [ University of Arkansas - Fayetteville, AR 72701 ] [ Ph: (479) 575-6324, 575-8630 (fax) ] [ http://definetti.uark.edu/~gpetris/ ] [__________________________________________________] ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help
