Skip to main content

Hands-on tutorial for parallel computing with R


Due to the increasing availability of powerful hardware resources, parallel computing is becoming an important issue, as a noticeable speedup may be achieved. The statistical programming language R allows for parallel computing on computer clusters as well as multicore systems through several packages. This tutorial gives a short, practical overview of four, in view of the authors, important packages for parallel computing in R, namely multicore, snow, snowfall and nws. First, the general principle of parallelizing simple tasks is briefly illustrated based on a statistical cross-validation example. Afterwards, the usage of each of the introduced packages is being demonstrated on the example. Furthermore, we address some specific features of the packages and provide guidance for selecting an adequate package for the computing environment at hand.

This is a preview of subscription content, access via your institution.


  • Bjornson R, Carriero N, Weston S (2007) Python NetWorkSpaces and parallel programs. Dr Dobb’s Journal, pp 1–7.

  • Dolkart V, Pronina L (2007) Change in computer hardware and software paradigms. Russian Electr Eng 78(10): 548–553

    Article  Google Scholar 

  • Dongarra, J, Foster, I, Fox, G, Gropp, W, Kennedy, K, Torczon, L, White, A (eds) (2003) Sourcebook of parallel computing. Morgan Kaufmann Publishers Inc., San Francisco

    Google Scholar 

  • Eddelbuettel D (2010a) CRAN task view: high-performance and parallel computing.

  • Eddelbuettel D (2010b) R SIG on high-performance computing.

  • Grama A, Karypis G, Kumar V, Gupta A (2003) Introduction to parallel computing. 2nd edn. Addison Wesley, Reading

    Google Scholar 

  • Hastie T, Tibshirani R, Friedman J (2009) The elements of statistical learning: data mining, inference, and prediction. 2nd edn. Springer, New York

    MATH  Google Scholar 

  • Knaus J (2010) Snowfall: easier cluster computing based on snow., R package version 1.83

  • Knaus J, Porzelius C, Binder H, Schwarzer G (2009) Easier parallel computing in R with snowfall and sfCluster. R J 1: 54–59

    Google Scholar 

  • R Development Core Team (2009) R: a language and environment for statistical computing. R Foundation for Statistical Computing, Vienna, Austria., ISBN 3-900051-07-0

  • REvolution Computing (2008) nws: R functions for NetWorkSpaces and Sleigh. REvolution Computing with support and contributions from Pfizer and Inc., R package version

  • Rossini A, Tierney L, Li NM (2007) Simple parallel statistical computing in R. J Comput Graph Stat 16(2): 399–420

    MathSciNet  Article  Google Scholar 

  • Schmidberger M, Morgan M, Eddelbuettel D, Yu H, Tierney L, Mansmann U (2009) State of the art in parallel computing with R. J Stat Softw 31(1).

  • Simon R, Radmacher MD, Dobbin K, McShane LM (2003) Pitfalls in the use of DNA microarray data for diagnostic and prognostic classification. J National Cancer Inst 95(1): 14–18

    Article  Google Scholar 

  • Sloan J (2004) High performance linux clusters with OSCAR, Rocks, OpenMosix, and MPI (Nutshell Handbooks). O’Reilly Media, Inc.

  • Stevens WR (1992) Advanced programming in the UNIX environment. 1st edn. Addison-Wesley, Reading

    MATH  Google Scholar 

  • Tierney L, Rossini AJ, Li MN, Sevcikova H (2008) Snow: simple network of workstations., R package version 0.3–3

  • Urbanek S (2009) Multicore: parallel processing of R code on machines with multiple cores or CPUs., R package version 0.1-3

Download references

Author information

Authors and Affiliations


Corresponding author

Correspondence to Manuel J. A. Eugster.

Additional information

Manuel J. A. Eugster, Jochen Knaus, Christine Porzelius, Markus Schmidberger, and Esmeralda Vicedo contributed equally to this work.

Rights and permissions

Reprints and Permissions

About this article

Cite this article

Eugster, M.J.A., Knaus, J., Porzelius, C. et al. Hands-on tutorial for parallel computing with R. Comput Stat 26, 219–239 (2011).

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI:


  • Parallel computing
  • R
  • Multicore
  • Snow
  • Snowfall
  • nws