Update: Okay. I’ve uploaded a new template and things seem to be fine now.
Update: I am aware the table of contents is not being displayed in bullet form as I intended. The web template I’m using seems to be buggy. It also seems to think this page is in Indonesian…Working on it!
Table of Contents:
- Reading/Writing Files
- How do you write a CSV in R with matrix names dimnames(M) intact?
- How to join dataframes in R (inner, outer, left, right)?
- Dropping Columns in Dataframes
- Dropping factor levels in a subsetted dataframe
- Remove rows with NA in your dataframe
- Creating an R dataframe row by row
- Fastest way to merge/join dataframes
- Lists and Vectors
- How to correctly use lists in R?
- Levels – what sorcery is this?
- R function for testing if a vector contains a given element?
- Converting lists to dataframe
- In R, what is the difference between  and [] notations accessing the elements of a list
- How to convert a factor to an integer/numeric without a loss of information
- How to access the last value of a vector
- Removing an element from a list
- Extracting the last n characters from a string
- Exceptions and Gotchas
- What is the biggest R gotcha you’ve run across?
- Exception handling in R
- Reading commandline parameters from an R script
- Assignment operators in R: ‘=’ vs ‘ ->
- Why is not (explicitly) calling return faster or better, and thus preferable?
- Why does TRUE == "TRUE" in R?
- What is the difference between ‘1L’ and ‘1’?
- Why does the number 1e99999 (31 9’s) cause problems?
- Examples of the perils of globals in R and Stata
- How to count TRUE values in a logical vector
- Plotting 2 graphs in the same plot
- How to plot 2 histograms together in R
- Histogram with a logarithmic scale
- The most underutilized visualization
- Rotating and spacing axis labels in ggplot2
- Shading a kernal density plot between 2 points
- Choosing between qplot() and ggplot() in ggplot2
- Intelligent point label placement in R
- Plotting a correlation matrix
- Plotting a 3D surface plot with contour map overlay, using R
- Side-by-side plots using ggplot2
- Ggplot2 cheat sheet
- Plot a human body in 2D
- Plotting 2 variables as lines using ggplot2
- Getting rid of axis values in an R plot
- Grouping Functions and Speed
- Making XKCD style plots in R
- Developing geographic thematic maps with R
- What can Matlab do that R cannot do?
- Where to learn C code to speed up your R functions
- How to organize large R programs
- The difference between library() and require()
- Unloading a package without restarting R
- What is the difference between R.exe, Rterm.exe, Rscript.exe, and Rcmd.exe?
- What is your preferred style for naming variables in R?
- In R, what exactly is the problem with having objects with the same base name as functions?
- Easter eggs in R
- Drawing an excellent cow
- Display a time clock on the R commandline
- What are slots?
- Get help for an R package
- Case Studies
Stack Overflow is awesome. Some of the worlds most brilliant programmers frequent the website and answertough questions. Wouldn’t that make it a great place to learn from? Yeah, I think so too.
This is why I’ve collated, The Guerilla Cookbook for R. It’s basically a number of Stack Overflow links organized and ordered in a way to help R programmers learn their way to the next level. If you are proficient in R, I hope these resources will help you get closer to being amazing. If you are just getting started with R, I’d suggest adding this page to your bookmarks and returning when you are familiar with the basics of R programming.
The cool thing is, this "book" essentially writes itself since most of the experts (and peer-reviewers) are answering the questions. Most of the questions are "real-world" and are asked by novice or intermediate programmers. We can easily add/remove/reorganize the contents as necessary.
How Was The Content Selected?:
I personally searched through Stack Overflow to find my favorite questions and shared them here.
The table of contents will have to be updated/reorganized over time as links are added and removed. But use whatever you can for now!