Tsallaka zuwa abun ciki
Justice Tech School

Base R Plots

plot, hist, barplot, boxplot and lines draw charts. Arguments set titles, labels and colours.

Example
x <- c(1, 2, 3, 4); y <- c(2, 4, 3, 6)
plot(x, y, type = "b", main = "Scores", xlab = "Round", ylab = "Points", col = "blue")

Exercise

Draw a histogram.

(x)

Quiz Test

Which draws a histogram?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.