A curated list of awesome tools to assist R ๐ฆ development.
Note before:
- Not all tools are available on CRAN; some might be available only via GitHub or GitLab.
- Only tools helpful for package development are included, and not other resources (like books, talks, presentations, etc.).
- Tools which are part of publicly archived/retired GitHub repositories are not included.
If you wish to suggest any additional tools, please make a PR request or raise an issue here.
Please note that the awesome-r-pkgtools
project is released with a
Contributor Code of
Conduct.
By contributing to this project, you agree to abide by its terms.
If you are not using the latest release of
pandoc, please change only the
README.Rmd
document.
Tools useful across all stages of package development (some of these are meta-packages and their component packages are also included in respective sections for the sake of completeness).
-
{pkgkitten}
(useful for creating new packages for R) -
{rcompendium}
(to make the creation of R package/research compendium easier) -
{golem}
(framework for building shiny applications) -
{leprechaun}
(leaner framework for building shiny applications) -
{fusen}
({rmarkdown}
-based) -
{pkgverse}
(for package meta-verse) -
{metamakr}
(for package meta-verse)
-
{available}
(to check if a package name is available to use) -
{collidr}
(to check for namespace collisions) -
{changer}
(to change the name of an existing R package)
-
{rprojroot}
(accessing files w.r.t. package root directory) -
{desc}
(manipulatingDESCRIPTION
files) -
{withr}
(to manage package side effects by safely and temporarily modifying global states) -
{pkgload}
(to simulate the process of installing and loading a package) -
{pkgbuild}
(to find tools needed to build packages)
{config}
(to manage environment specific configuration values)
{pkgcache}
(to cache โCRANโ-like metadata and packages)
-
{roxygen2}
(to generate R package documentation from inline R comments) -
{Rd2roxygen}
(in case you inherit a project where documentation was not written using{roxygen2}
) -
{sinew}
(generate{roxygen2}
skeletons) -
{roclang}
(helpers for diffusing content across function documentation) -
{Rdpack}
(for inserting references, figures, and evaluated examples in Rd docs) -
{roxygen2md}
(using Markdown syntax in package documentation) -
{rd2list}
(converts Rd docs to a human-readable list) -
roxygen2Comment
(Rstudio addin for adding and remove{roxygen2}
comment)
-
{katex}
(to convert latex math expressions to HTML for use in package manual pages) -
{mathjaxr}
(provides โMathJaxโ and macros to enable its use withinRd
files for rendering equations in the HTML help files)
-
{knitr}
(a general-purpose tool for dynamic report generation to be used as a vignette builder for R package vignettes) -
{rmarkdown}
(to convert R Markdown documents to a variety of formats) -
{prettydoc}
(creates lightweight yet pretty vignettes) -
{learnr}
(to turn any R Markdown document into an interactive tutorial)
-
{pkgdown}
(static website for package documentation) -
{gitdown}
(software changes as a gitbook) -
{altdoc}
(use docute or docsify to create a static website for package documentation)
{potools}
(for translating messages and checking the โhealthโ of the messaging corpus)
{lifecycle}
(to manage the life cycle of exported functions)
-
{badger}
(query information and generate badges for using inREADME
andGitHub Pages
) -
{hexSticker}
(helper functions for creating reproducible hexagon sticker purely in R) -
hexwall
(to create a wall of hexstickers)
{xaringan}
(an R Markdown output format forremark.js
slides)
{bookdown}
(authoring framework for books and technical documents with R Markdown)
-
{fledge}
(streamlines the process of updating change logs and versioning R packages developed in git repositories) -
{newsmd}
(utilities to add updates to theNEWS.md
file)
-
{docreview}
(to check quality of docs) -
{spelling}
(to check for spelling mistakes) -
{gramr}
(for grammar suggestions)
-
{testthat}
(a testing framework for R that is easy to learn and use; also provides snapshot testing) -
{tinytest}
(zero-dependency unit testing framework that installs tests with the package) -
{RUnit}
(a standard Unit Testing framework, with additional code inspection and report generation tools) -
{testit}
(a simple package for testing R packages) -
{roxytest}
(inline{testthat}
tests with{roxygen2}
) -
{exampletestr}
(tests based on package examples) -
{unitizer}
(simplifies regression tests by comparing objects produced by test code with earlier versions of those same objects) -
{r-hedgehog}
(property based testing) -
{autotest}
(automatic mutation testing of R packages)
-
{shinytest}
(testing Shiny apps) -
{shinytest2}
(testing Shiny apps using a headless Chromium web browser)
-
{httptest}
(a test environment for HTTP requests in R) -
{httptest2}
(the same for{httr2}
package)
{vdiffr}
(visual regression testing)
-
{mockthat}
(function mocking for unit testing to third-party packages) -
{mockr}
(allows mocking functions in the package under test) -
{testdown}
(turn{testthat}
results into a{bookdown}
project)
-
{testthis}
(RStudio addins for working with files that contain tests) -
{xpectr}
(builds unit tests with the{testthat}
package by providing tools for generating expectations)
-
{codetools}
(code analysis tools for R) -
{goodpractice}
(Swiss army knife for good practices) -
{inteRgrate}
(provides an opinionated set of rules for R package development) -
{pkgcheck}
(checks if package follows good practices recommended for packages in therOpenSci
ecosystem) -
{rchk}
(provides several bug-finding tools that look for memory protection errors in C source code using R API) -
{sourcetools}
(tools for reading, tokenizing, and parsing R code)
-
{covr}
(computes code coverage) -
{covrpage}
(provides summaryREADME
of code coverage and corresponding tests)
-
{lintr}
(static code analysis) -
{roger}
(provides tools for grading the coding style and documentation of R scripts) -
{cleanr}
(tests code for some of the most common code layout flaws)
{cyclocomp}
(to index the complexity of a function)
-
{dupree}
(identifies code blocks that have a high level of similarity within a set of R files) -
{rscc}
(provides source code similarity evaluation by variable/function names) -
{SimilaR}
(quantifies the similarity of the code-base of R functions by means of program dependence graphs)
{cloc}
(counts blank lines, comment lines, and physical lines of source code in source files)
-
{bench}
(provides high precision benchmarks for R expressions) -
{microbenchmark}
(provides infrastructure to accurately measure and compare the execution time of R expressions) -
{touchstone}
(benchmarking pull requests)
-
{profvis}
(to profile and visualize profiling data) -
{proffer}
(to create friendlier, faster visualizations for profiling data) -
{jointprof}
(to profile packages with native code in C, C++, Fortran, etc.)
-
{styler}
(to format code according to a style guide) -
{stylermd}
(to format text in Markdown documents) -
{formatR}
(to format R source code) -
AlignAssign
(RStudio addin that aligns the assignment operators within a highlighted area)
-
{pkgdepends}
(to find recursive dependencies of from various sources) -
{deepdep}
(to visualize and explore package dependencies) -
{itdepends}
(to assess usage, measure weights, visualize proportions, and assist removal of dependencies) -
{DependenciesGraphs}
(to visualize package dependencies) -
{pkgnet}
(to build a graph representation of a package and its dependencies) -
{functiondepends}
(to find functions in an unstructured directory and explore their dependencies) -
{pkgndep}
(checks the heaviness of the packages used) -
{oysteR}
(to secure package against insecure dependencies) -
{attachment}
(to deal with package dependencies during package development)
-
{rcmdcheck}
(to runR CMD check
form R programmatically) -
{rhub}
(to runR CMD check
on CRAN architectures) -
{checkhelper}
(to help avoid problems with CRAN submissions) -
{foghorn}
(to check for results and submission portal status) -
{urlchecker}
(to checks for URL rot)
-
{cranlogs}
(for computing CRAN download counts) -
{packageRank}
(for visualizing CRAN download counts)
CI/CD: continuous integration and either continuous delivery or continuous deployment
-
actions
(for GitHub Actions) -
r-appveyor
(for AppVeyor) -
{tic}
(for Circle CI and GitHub Actions) -
{jenkins}
(for Jenkins CI) -
{cronR}
(to schedule R scripts/processes with the cron scheduler)
-
{digest}
(for the creation of hash digests of arbitrary R objects) -
{hash}
(implements a data structure similar to hashes in Perl and dictionaries in Python but with a purposefully R flavor) -
{gpg}
(GNU privacy guard for R)
{fakemake}
(to mock Unix Make build system in case it is unavailable)
{valtools}
(in clinical research and drug development)
-
{debugme}
(provides helpers to specify debug messages as special string constants, and control debugging of packages via environment variables) -
{debugr}
(tools to print out the value of R objects/expressions while running an R script) -
{winch}
(provides stack traces for call chains that cross between R and C/C++ function calls) -
{flow}
(to visualize as flow diagrams the logic of functions, expressions, or scripts, which can ease debugging)
-
{checkmate}
(fast and versatile argument checks) -
{assertthat}
(to declare the pre and post conditions that you code should satisfy and to produce friendly error messages) -
{assertive}
(provides readable check functions to ensure code integrity) -
{pkgcond}
(better error messages for package users) -
{dreamerr}
(a simple and intuitive, yet powerful and flexible, way to check the arguments passed to a function and to offer informative error messages)
-
{codemetar}
(provides utilities to generate, parse, and modifycodemeta.jsonld
files automatically for R packages) -
{codemeta}
(a leaner version of{codemetar}
) -
{cffr}
(provides utilities to generate, parse, modify and validateCITATION.cff
files automatically for R packages) -
{pkgapi}
(to create the map of function calls in a package) -
{packagemetrics}
(for comparing among packages) -
{devtoolbox}
(to create a summary report for R package and to extract dependency statistics in a tidy data frame) -
{pkgattrs}
(useful for getting information on the contents of any R package) -
{foreman}
(for unpacking, interrogating and subsetting R packages) -
{sessioninfo}
(to include R session information)
-
{revdepcheck}
(for automated, isolated, reverse dependency checking) -
{xfun}
(specifically,xfun::rev_check()
)
To thank the contributors or maintainers of packages you rely on.
-
{thankr}
(to find out who maintains the packages you are using) -
{allcontributors}
(to help acknowledge all contributions)
-
{containerit}
(to package R script/session/workspace and all dependencies as aDocker
container by generating a suitableDockerfile
) -
{usethat}
(to automate analytic project setup tasks)
-
{memtools}
(to solve memory leaks)
{TODOr}
(RStudio addin to list things that you need to do or change)
-
{prefixer}
(prefix function with their namespace ) -
{rstudioapi}
(to conditionally access the RStudio API from CRAN packages) -
{gitignore}
(to fetch gitignore templates) -
{precommit}
(pre-commit hooks) -
{DIZutils}
(helpers for packages dealing with database connections)
Please note that the awesome-r-pkgtools project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.