neurocInstall (version 0.12.0)

neuro_install: Neuroconductor Installer

Description

Install function for neuroconductor packages

Usage

neuro_install(
  repo,
  release = c("stable", "current"),
  release_repo = latest_neuroc_release(),
  upgrade_dependencies = FALSE,
  type = getOption("pkgType"),
  ...
)

neuroc_install(...)

neurocLite(...)

Arguments

repo

Package name in neuroconductor

release

Stable or current (development) versions/branches

release_repo

Repository for release repository, passed to install.packages. If release_repo = "github", then it will install using GitHub. If you set this using make_release_version or specify the URL directly, it will override release option.

upgrade_dependencies

Should dependencies be updated? passed to install if using release_repo = "github"

type

character, indicating the type of package to download and install, passed to install.packages.

...

additional arguments passed to install.packages or install_github if release_repo = "github"

Value

Result from install.packages or install_github

Examples

Run this code
# NOT RUN {
   tlib = tempfile()
   dir.create(tlib, showWarnings = FALSE)
   system.time({
   install.packages("oro.asl",
   lib = tlib,
   repos = "https://neuroconductor.org/releases/2019/12/")
   })
   repos = getOption("repos")
   print(repos)
   #if (repos["CRAN"] == "@CRAN@") {
   #    repos["CRAN"] = "https://cloud.r-project.org"
   #    options(repos = repos)
   #}
   options(repos = NULL)
   print(getOption("repos"))
   neuro_install("oro.asl", lib = tlib,
   release_repo = "https://neuroconductor.org/releases/2019/12")
   options(repos = repos)
 
# }
# NOT RUN {
   neuro_install("cifti", type = "source", lib = tlib)
   neuro_install("cifti",
   release_repo = latest_neuroc_release("stable"),
   lib = tlib)

   neuro_install("cifti", release_repo = "github")
# }
# NOT RUN {
# }

Run the code above in your browser using DataCamp Workspace