r intro for munich google io extended

10
An Intro to R ...or who survived the sinking of the Titanic? [email protected] - @dakoller for Google Extended IO 2013/Munich Donnerstag, 16. Mai 13

Upload: daniel-koller

Post on 27-Jan-2015

104 views

Category:

Technology


1 download

DESCRIPTION

 

TRANSCRIPT

Page 1: R Intro for Munich Google IO Extended

An Intro to R...or who survived the sinking of the Titanic?

[email protected] - @dakoller

for Google Extended IO 2013/Munich

Donnerstag, 16. Mai 13

Page 2: R Intro for Munich Google IO Extended

R is...• an open source interpreted programming language for statistical

computations. • As such it competes with software packages like SPSS, SAS and partially

MathLab.• You can access it from the command line, from a number of desktop & web

clients and from APIs.• You can use the results of R computations in databases, web applications,

graphics.• R supports

Linear & nonlinear regression Clustering

Timeseries analysis Extensive graphics

Classification ...and much more via packages!

Donnerstag, 16. Mai 13

Page 3: R Intro for Munich Google IO Extended

Graphics in R

R Standard Graphics Up to date graphics with ggplot2 1)

1) http://www.r-bloggers.com/maps-with-ggplot2/ - 2) http://glimmer.rstudio.com/winston/stocks/

Interactive web graphics with Shiny 2)

Donnerstag, 16. Mai 13

Page 4: R Intro for Munich Google IO Extended

• R can handle the semantics of dates & times very well.

• Needed to separate seasonal special influences from data sources to find the real trend.

Timeseries analysis with R

1) http://www.stat.pitt.edu/stoffer/tsa3/R_toot.htm - Plot: decomposed time series

Donnerstag, 16. Mai 13

Page 5: R Intro for Munich Google IO Extended

Clustering with R

• Needed to find commonalities in datasets

• Also needed to find „similar“ items.

• Plots support visual interpretation: ClusPlot, Dendrogram, Decision Trees

Donnerstag, 16. Mai 13

Page 6: R Intro for Munich Google IO Extended

Shiny Showcase „Bienenschwärme in the wild“ http://glimmer.rstudio.com/dakoller/happyBees/

Donnerstag, 16. Mai 13

Page 7: R Intro for Munich Google IO Extended

..in RStudio

• data(Titanic)

• summary(Titanic)

• Number of cases in table: 2201

• Number of factors: 4 -> (Class, Age, Sex --> Survived Yes/No)

• mosaicplot(Titanic,color = TRUE)

Donnerstag, 16. Mai 13

Page 8: R Intro for Munich Google IO Extended

Who survived the sinking of the Titanic?

Donnerstag, 16. Mai 13

Page 10: R Intro for Munich Google IO Extended

Resources

• R on Wikipedia: http://www.quickiwiki.com/en/R_(programming_language)

• RStudio: desktop client for Windows, Mac OS X and Linux: http://www.rstudio.com/ide/

• Shiny, R web app framework for interactive apps: http://www.rstudio.com/shiny/

• Quick-R: http://www.statmethods.net/

• inside-R: Community/blog site about R http://www.inside-r.org/

• R-Bloggers: feed of R-relevant blogs: http://www.r-bloggers.com/

Donnerstag, 16. Mai 13