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.1.3 was released in March 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 user base to help when you run into issues

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 
quantile(x,c(.1,.9),type = 1)
10% 90% 
 14  38 
t.test(x,conf.level=0.9)

    One Sample t-test

data:  x
t = 16.2809, df = 32, p-value < 2.2e-16
alternative hypothesis: true mean is not equal to 0
90 percent confidence interval:
 24.10943 29.70875
sample estimates:
mean of x 
 26.90909 
hist(x)

plot of chunk unnamed-chunk-3