dose <-c(20,30,40,45,60)
drugA<-c(16,20,27,40,60)
drugB<-c(15,18,25,31,40)
plot(dose,drugA,type = "b")
plot()函数的基本形式:plot(x,y,…)
基本含义是,将x置于横轴,y置于纵轴,绘制(x,y)的点集,然后用线段将其连接起来。
参数“…”,是用来说明画出什么类型的图形。
具体用法如下:
plot(dose,drugA,type = "p")
plot(dose,drugA,type = "l")
plot(dose,drugA,type = "b")
plot(dose,drugA,type = "c")
plot(dose,drugA,type = "o")
plot(dose,drugA,type = "h")
plot(dose,drugA,type = "s")
plot(dose,drugA,type = "S")
plot(dose,drugA,type = "n")