June 2017
Beginner to intermediate
576 pages
15h 22m
English
Install the packages if needed:
install.packages("car") install.packages("MASS")
Assign the libraries:
library(car) library(MASS)
Generate the skewed data:
set.seed(1010) x<-rexp(1000) # exponential sample with parameter 1 par(mfrow=c(2,3))
Plot the histogram and normal probability plots. The par() function specified that they will be part of the first row of plots shown in the next section:
hist(x) qqnorm(x) # Normal probability plot for original variable