In [ ]:
# Summary:
# pair to create scatterplot matrix for each variable
# pairs(∼ mpg + displacement + horsepower + weight + acceleration , Auto)

In [ ]:
x <- c(2, 7, 5)
x

In [ ]:
y <- seq(from = 4, length = 3, by = 3)
y

In [ ]:
z <- matrix(seq(1, 12), 4, 3)
z

In [ ]:
z[3:4, 2:3]

In [ ]:
z[,1]

In [ ]:
z[,1, drop=FALSE]

In [ ]:
dim(z)

In [ ]:
ls()

In [ ]:
rm(y)

In [ ]:
ls()

In [ ]:
x <- runif(50)

In [ ]:
y <- rnorm(50)

In [ ]:
plot(x, y)

In [ ]:
plot(x, y, xlab = "lala", ylab = "haha", pch = "*", col = "blue")

In [ ]:
par(mfrow = c(2, 1))

In [ ]:
plot(x, y)
hist(y)

In [ ]:
library(ISLR)

In [ ]:
str(Auto)

In [ ]:
class(Auto)

In [ ]:
summary(Auto)

In [ ]:
boxplot(mpg ~ cylinders, data = Auto)
attach(Auto)
identify(mpg, cylinders, names)