Book Image

R High Performance Programming

Book Image

R High Performance Programming

Overview of this book

Table of Contents (17 chapters)
R High Performance Programming
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Seeking fast alternative packages in CRAN


One key advantage of R is its rich and active open source community, CRAN. As of the time of writing, there are over 6,000 R packages in CRAN. Given this, it is common that multiple packages offer the same functionalities. Some of these alternatives are designed specifically to improve the performance of a base or an existing CRAN package's performance. Others do not target performance improvement explicitly, but nevertheless achieve it as a by-product.

An example of an alternative fast package developed to achieve performance gains is the fastcluster package. It was developed to improve the speed of hierarchical clustering provided by the base package through the hclust function. Depending on how the distance matrix gets updated after every branch merging in the hierarchical clustering procedure, its time complexity can vary significantly. The fastcluster package is developed using an optimized C++ code that improves the speed significantly compared...