[R] multiple lines and plot

Mauricio Cardeal mcardeal at ufba.br
Wed Sep 20 11:27:56 CEST 2006


Ok. I´ve already tried ?lines. An example:

x <- c(1,2,3,4,5,6)
y <- c(3,5,2,4,1,4)
z <- c(2,3,4,3,2,1)
plot(x,y)
lines(x,y)
lines(x,z)

Here is the point: how to show the points under the second line (x,z) ?

Thanks
Mauricio


David Barron escreveu:
> ?lines
>
> On 20/09/06, Mauricio Cardeal <mcardeal em ufba.br> wrote:
>> Hi. Please, how can I put together 2 or more lines at the same
>> scatterplot ? Example: measures of protein intake (quantitative) of 4
>> children over 30 days, by day. How to plot all children at same graphic:
>> Protein X Time ? Is there any command like "overlay" ?
>>
>> Thank you,
>> Mauricio
>>
>> ______________________________________________
>> R-help em stat.math.ethz.ch mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide 
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>
>
>



More information about the R-help mailing list