R

Michael Crawford
June 4th, 2015

History of R

  • R is based upon the S language
  • S was written in 1976 to be a statistical analysis environment
  • R was first released in 1993 as private software but was made free in 1995
  • In 2000 the 1.0.0 version of R was release
  • R version 3.2.2 was released in August 2015

Benefits of R

  • Built from the ground up with statistics and data mining in mind
  • Interactive (allows you to “play” with the data)
  • Large and active user base to help when you run into issues
  • There's a package for that
  • Very good (and free) Integrated Development Environment (RStudio)

Basic Statistics

x <- c(23, 33, 14, 15, 42, 28, 33, 45, 23, 34, 39, 
       21, 36, 23, 34, 36, 25, 9, 11, 19, 35, 24, 
       31, 29, 16, 23, 34, 24, 38, 15, 13, 35, 28)
summary(x)
   Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
   9.00   21.00   28.00   26.91   34.00   45.00 
mean(x)
[1] 26.90909
sd(x)
[1] 9.494616
quantile(x,c(.1,.9),type = 1)
10% 90% 
 14  38 
hist(x)

plot of chunk unnamed-chunk-4

Z Tests

Error in library(TeachingDemos) : 
  there is no package called 'TeachingDemos'