Commands
# Scatterplot
plot(mtcars$wt, mtcars$mpg)
# Add regression line
abline(lm(mtcars$mpg~mtcars$wt))
# Add lowess line
lines(lowess(mtcars$wt,mtcars$mpg))
# Scatterplot matrix
pairs(~mpg+disp+drat+wt,data=mtcars)
# Histogram
hist(mtcars$mpg)
# Dotchart
dotchart(mtcars$mpg)
# Barplot
barplot(table(mtcars$gear))
# Piechart
pie(c(2,3,4,5,2))
# Boxplot
boxplot(mpg~cyl,data=mtcars)
# Adding other information