12 nifty tips for scientists who use computers
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.
Simple things are good. Here is a list of 12 things that I find simple and useful, yet not many of my colleagues use them. The list is R-biased.
Knitr. Intuitive tool to integrate R and text to make reports with fancy fonts, figures, syntax-highlighted R code and equations. If you use R studio, then learning Knitr is remembering a bunch of simple commands and knowing where the ‘knit’ button is. My dream is that, in the near future, every published paper will have an appendix consisting of an .html file produced by Knitr, which will contain all of the data processing and analytical steps. Look for the .Rmd file format in R studio.
Focus. A distraction free text editor — there is nothing else than you and the text on your screen. Great if you need to 100% focus on writing.
Solarized color theme. Some combinations of colors on the screen are unhealthy. Black font on white background is about as healthy as gazing into a light bulb; imagine doing this for several hours almost every day for the rest of your life. Luckily, there is a color theme that is designed to be gazed into: it’s the Solarized theme. It has several unique properties such as selective contrast, symmetric lightness, both dark and light versions, and it is available for Firefox, Visual Studio, R Studio, Emacs, Vim, Gnome Terminal, Gedit and others.
Rcpp. As Hadley Wickham puts it in his excellent post, sometimes R is just not fast enough and you can’t speed things up with apply-like functions and vectorizations (e.g. in stochastic simulations). Rcpp is an R to C++ interface that speeds things up considerably, and it only requires elementary knowledge of C++. Check out the post, and you will see that the Rcpp’s “syntactic sugar” and its data formats are accessible even to C++ dummies. Rcpp has solved all of my remaining issues with R’s speed.
Remarkable. Markdown editor. Simple.
R presentations. Yes, you can make presentations in R (example here). They are minimalistic, can be saved as .html (making them portable), and they can be easily provided on-line; useful for R-related teaching. Look for the .Rpres file format in R studio.
Google URL shortener. Have you ever wrestled with an inconveniently long URL, trying to fit it into a manuscript, into a comment in MS Word, teaching materials, or just into an e-mail? This on-line utility from Google can help.
LibreOffice Draw. It is like Inkscape, CorelDraw or Adobe Illustrator, but it is easier to use, and it is free. Although lightweight, it has exactly the functionality one needs for drawing and editing scientific schemes, plots and illustrations. You can learn it in 5 minutes.
LaTeX equations. LaTeX is great, but it can also be a nightmare, especially when used in collaborative projects. However, the LaTeX equation syntax has a potential even if you don’t code your manuscripts. LaTeX equations can be used in Knitr (see above), and there is a plug-in for LibreOffice that supports LaTeX equations. I also use uncomplied LaTeX equations: e.g. when commenting on collaborative manuscripts, in reviews for journals, in e-mails – always when I need to fit a mathematical idea into a piece of plain text.
Dropbox file history. Did you know that Dropbox saves complete history of every file in the Dropbox folder for up to a month? Kind of a data backup that saved my day several times already, after I accidentally overwrote contents of an important file. Also quite handy for collaborative projects — it works as a primitive version control system, without the technical challenge of Git.
Nature and Science yearly subscription. Nature is $119 for post-docs and $199 for humans, Science is $50 for post-docs and $99 for humans; EU prices are slightly higher. I think that it’s a good deal, considering that you get a printed issue every week. I love listing through an actual paper issue of Science or Nature when I have spare 10 minutes. The first part of the journal is news and popular science, keeping me up to date with what’s hot.
SSH. Easy and safe way to connect computers. This effectively eliminates the need to buy expensive laptops. Here is a visionary suggestion: Buy only cheap laptops, and if you need computational power, connect the laptop to a second-hand, bulky, noisy, and powerful server in your closet through SSH. Or actually, how about dumping the laptop and using Raspberry Pi instead. Or even better, you can dump your server too, or make it more useful by converting it into a grow-box for hemp; then you can buy a dozen of second-hand Playstations 3, use their GPUs to make a Playstation cluster with 96 cores, and access it through SSH from your Raspberry Pi – all for $1000.
R-bloggers.com offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.