R is very powerful and is becoming the language of data scientists. But some things require a bit of learning and are not obvious to the R newcomer. Here are five useful tips if you are just starting out:
- Sometimes data is not in the correct format and you need to reshape data to use it in R. Instead of using external software you can do it directly in R.
- Plotting multiple series in the same figure. This can be accomplished using R ggplot2 library producing better looking graphics.
- If you do Network Analysis, you’ll need to partition the graph into communities. Finding communities in R is easy with the igraph package.
- Still playing with graphs, you can colour different nodes according to some data property. Check how to colour graph nodes in R.
- R ggplot2 allows you to accept most of the defaults and have great plots, but sometimes you might want to customise them further. Check how to customise ggplot2 axes labels.
Extra: If you use Sweave to automate your reports with live data in R, you might sometimes want to extract the R snippets to a new R file. Instead of copying and pasting, try this: