\\ We recommend using [[http://www.r-project.org/|R]] for the homework assignments. Since there are many ways to reach the correct solution, using R is not a requirement. You can certainly use MatLab if you prefer. Or even code everything from scratch (very instructive). However you may find R practical for this course and useful in the future. ===== Tutorial ===== [[http://www.cs.princeton.edu/~sgerrish|Sean Gerrish]] will give a tutorial on Tuesday 9/02. Same room and same time as the usual tuesday lectures. ===== Using R at Princeton ===== You can find copies of R for your personal computer at [[http://www.r-project.org/|http://www.r-project.org/]]. It is also installed on the CS linux machines (e.g., tux.cs.princeton.edu and cycles.cs.princeton.edu ) and the hats machines (hats.princeton.edu). ===== Sample scripts, data, etc. ===== - The slides of the 2008 tutorial are available [[http://www.cs.princeton.edu/courses/archive/spr08/cos424/R/|here]]. - An example R script (with comments) can be found [[http://www.cs.princeton.edu/~sgerrish/cos424/r_examples.r|here]]. - The commands used in the tutorial can be found [[http://www.cs.princeton.edu/~sgerrish/cos424/r_tutorial_commands.r|here]]. - The movies dataset (included in the ggplot2 package) can be found [[http://www.cs.princeton.edu/~sgerrish/cos424/movies.csv|here]]. ===== About R ===== //"R is a system for statistical computation and graphics. It consists of a language plus a run-time environment with graphics, a debugger, access to certain system functions, and the ability to run programs stored in script files."// To properly prepare yourself for the class, the first thing you should do is download and install the program. Familiarize yourself with how to run it. Start working through the Introduction to R (if you actually make it all the way through, you'll be more than prepared). Those of you familiar with Matlab should find transitioning to R fairly easy. But like most systems, the best way to learn is to dive in and start playing around with it. ===== Summary ===== - High-level introduction to R: what is it good for? - R syntax and data structures - R syntax examples (session) - Graphics in R - Graphics xamples (session) ===== Useful links ===== - [[http://www.r-project.org/|The R Project for Statistical Computing]]. //The main page for the R project//. - [[http://www.rseek.org|RSeek.org]]. //A search engine for R related materials//. - [[http://ess.r-project.org/|ESS: Emacs Speaks Statistics]]. //Add-ons for emacs that allow it to interface with R//. - [[http://cran.r-project.org/doc/manuals/R-intro.html|An Introduction to R]] (PDF version available [[http://cran.r-project.org/doc/manuals/R-intro.pdf|here]]) //A good introduction/tutorial for R//. - [[http://addictedtor.free.fr/graphiques/|R Graph Gallery]]. //A gallery of pretty graphs made with R//.