Re: [R] Question regarding R plot

2010-04-21 Thread Uwe Ligges
optimize(function(x) -scores(x), interval=c(0.5, 0)) $minimum [1] 0.1830174 $objective [1] -11.67820 So the maximum is at x=0.183 with a score of 11.7, numerically. Uwe Ligges On 17.04.2010 16:30, Akito Y. Kawahara wrote: Hi, I am new to R, and have a quick question regarding an R script

[R] Question regarding R plot

2010-04-17 Thread Akito Y. Kawahara
Hi, I am new to R, and have a quick question regarding an R script that I received from a kind colleague. I am trying to determine the peak (maximum value) of the graph that is plotted when executing the following. There is an input file called rates_values.txt which begins as: rateValue

Re: [R] Question regarding R plot

2010-04-17 Thread Charles C. Berry
On Sat, 17 Apr 2010, Akito Y. Kawahara wrote: Hi, I am new to R, and have a quick question regarding an R script that I received from a kind colleague. I am trying to determine the peak (maximum value) of the graph that is plotted when executing the following. There is an input file called

Re: [R] Question regarding R plot

2010-04-17 Thread David Winsemius
On Apr 17, 2010, at 12:45 PM, Charles C. Berry wrote: On Sat, 17 Apr 2010, Akito Y. Kawahara wrote: Hi, I am new to R, and have a quick question regarding an R script that I received from a kind colleague. I am trying to determine the peak (maximum value) of the graph that is plotted when

Re: [R] Question regarding R plot

2010-04-17 Thread David Winsemius
On Apr 17, 2010, at 1:18 PM, David Winsemius wrote: On Apr 17, 2010, at 12:45 PM, Charles C. Berry wrote: On Sat, 17 Apr 2010, Akito Y. Kawahara wrote: Hi, I am new to R, and have a quick question regarding an R script that I received from a kind colleague. I am trying to determine the

Re: [R] Question regarding R plot

2010-04-17 Thread Akito Y. Kawahara
Thanks, this is really great! Just another quick question - if one were to calculate the mean of this curve, what command would you suggest? Optimize doesn't allow you to search for a mean value since it is only working on one point, and am just curious if there is a quick way to do this. Sorry

Re: [R] Question regarding R plot

2010-04-17 Thread David Winsemius
On Apr 17, 2010, at 3:13 PM, Akito Y. Kawahara wrote: Thanks, this is really great! Just another quick question - if one were to calculate the mean of this curve, what command would you suggest? Optimize doesn't allow you to search for a mean value since it is only working on one point, and