Multiple Plots in the Same Figure [R]
I would like to plot two functions f开发者_如何学C1 and f2 on the same graph. With the following code, I found that the scale of the y axes for the two plots are different. Is there a way to make the scales same?
plot(f1, 0, 1)
par(new=TRUE)
plot(f2, 0, 1)
Use the curve
function:
plot(f1, 0, 1)
curve(f2, 0, 1, add=TRUE)
精彩评论