Slide 64
Slide 64 text
# set graphic params: par
par(mar = c(3, 3, 0.5, 0.5), tcl = -0.2,
mgp = c(1.5, 0.3, 0), bty = "l")
# create & set a new plot: high level
plot(0, 0, type = "n", xlab = "x", ylab = "y",
xlim = c(min(x), max(x)),
ylim = c(min(y1, y2), max(y1, y2)))
# add elements: low level funcs.
lines(x, y1, col = "red")
lines(x, y2, col = "blue")
points(x, y1, col = "red")
points(x, y2, col = "blue", pch = 2)
Basic plotting functions in {graphics}