[R] multiple plots

arun smartpink111 at yahoo.com
Sat Mar 8 17:09:36 CET 2014


Hi,
Check ?matplot()
 matplot(c,cbind(a,b,d),type="l",ylab="Dependent Var")

#BTW, there is a typo in 'b'. (0,748).

A.K.


Hi, 

I have some values that I need to represente in the same plot. 
For exemple, if I have, 

c<-c(200,205,210,215,220,225,230,235) 
a<-c(0.032,0.44,0.86,0.65,0.53,0.213,0.46,0.231) 
b<-c(0.325,0.657,0.784,0.236,0.798,0.287,0,748,0.785) 
d<-c(0.786,0.217,0.538,0.513,0.870,0.326,0.647,0.217) 

c is a independente variable (represented in x axis) and a, b, d
 are diferente dependente varible (represented in a y axes). a, b and d 
should be diferent lines, How can I do that? 

Thank you



More information about the R-help mailing list