Re: [R] Graph f(x) = 1/x

2017-09-19 Thread ruipbarradas
Hello, I believe that the easiest way is curve(1/x, -5, 5) Also, you're missing a '-' in y < 1/x, it should be y <- 1/x Hope this helps, Rui Barradas Citando AbouEl-Makarim Aboueissa : Dear All: good morning I am trying to graph the function y=f(x)=1/x over

Re: [R] Graph f(x) = 1/x

2017-09-19 Thread Ivan Calandra
It's always good to start a new session when you don't understand what's wrong, because sometimes your code is correct, but you use old data without knowing it :) Ivan -- Dr. Ivan Calandra TraCEr, Laboratory for Traceology and Controlled Experiments MONREPOS Archaeological Research Centre and

Re: [R] Graph f(x) = 1/x

2017-09-19 Thread AbouEl-Makarim Aboueissa
Dear Zeileis: Thank you very much abou On Tue, Sep 19, 2017 at 4:13 AM, Achim Zeileis wrote: > > > On Tue, 19 Sep 2017, AbouEl-Makarim Aboueissa wrote: > > Dear All: good morning >> >> I am trying to graph the function y=f(x)=1/x over the interval (-5,5). But >> I am

Re: [R] Graph f(x) = 1/x

2017-09-19 Thread Achim Zeileis
On Tue, 19 Sep 2017, AbouEl-Makarim Aboueissa wrote: Dear All: good morning I am trying to graph the function y=f(x)=1/x over the interval (-5,5). But I am getting an error message. Please see below. I am getting the error message: *Error in xy.coords(x, y, xlabel, ylabel, log) : * * 'x'

[R] Graph f(x) = 1/x

2017-09-19 Thread AbouEl-Makarim Aboueissa
Dear All: good morning I am trying to graph the function y=f(x)=1/x over the interval (-5,5). But I am getting an error message. Please see below. I am getting the error message: *Error in xy.coords(x, y, xlabel, ylabel, log) : * * 'x' and 'y' lengths differ* x x <- seq(-5, 5, 0.01) y < 1/x