min_r_version {jwutil}R Documentation

Find minimum R version required for package

Description

Recursively search dependencies for R version, and find the highest stated R version requirement.

Usage

min_r_version(pkg)

Arguments

pkg

string with name of package to check

Source

Based on ideas from http://stackoverflow.com/questions/38686427/determine-minimum-r-version-for-all-package-dependencies

Examples

base <- c(
  "base", "compiler", "datasets", "grDevices", "graphics",
  "grid", "methods", "parallel", "profile", "splines", "stats",
  "stats4", "tcltk", "tools", "translations"
)
## Not run: 
base_reqs <- lapply(base, min_r_version)
contrib <- c(
  "KernSmooth", "MASS", "Matrix", "boot",
  "class", "cluster", "codetools", "foreign", "lattice",
  "mgcv", "nlme", "nnet", "rpart", "spatial", "survival"
)
contrib_reqs <- lapply(contrib, min_r_version)
min_r_version("icd")

## End(Not run)

[Package jwutil version 1.2.3 Index]