index.utf8

All code for this document is located at here.

Installing Neuroconductor Packages

Install and start the latest release version of R. Although the installer will try to download and install devtools, there may be some system requirements for devtools that you may need before going forward. Please visit installing devtools before going forward if you do not have devtools currently installed.

Then, you can install a package using the following command:

## try http:// if https:// URLs are supported
source("https://neuroconductor.org/neurocLite.R")
neuro_install("PACKAGE")

where PACKAGE is the name of the package you’d like to install, such as fslr. For example, if we want to install neurohcp and fslr we can run:

source("https://neuroconductor.org/neurocLite.R")
neuro_install(c("fslr", "neurohcp"))

Installing the neurocInstall package

The neurocInstall package contains the neurocLite/neuro_install functions, as well as others relevant for Neuroconductor. You can install the package as follows:

source("https://neuroconductor.org/neurocLite.R")
neuro_install("neurocInstall")

After installation, you can use neurocInstall::neurocLite() to install packages without source-ing the URL above.

Installing Stable/Current/Release Versions

Stable Versions

In Neuroconductor, there are stable versions, which correspond to a submitted package. This stable version has passed the Neuroconductor checks on Travis for Linux using the other packages in Neuroconductor that are in Neuroconductor at the time of submission. Thus, if you install this package with all the dependencies listed for this package (using specific Neuroconductor versions), it should work.

To install a stable version (which should be the default), you can run:

source("https://neuroconductor.org/neurocLite.R")
neuro_install(c("fslr", "neurohcp"), release = "stable")

Current Versions

In Neuroconductor, a “current” version mirrors the repository of the developer of the package. This does not ensure that the package is passing Neuroconductor checks, but will give you the development version from that developer. This, at least, standardizes the username for all the repositories in Neuroconductor. You can install a current version using:

source("https://neuroconductor.org/neurocLite.R")
neuro_install(c("fslr", "neurohcp"), release = "current")

Release Versions

Every few months, we snapshot all of Neuroconductor in their current forms. We save the source tarballs as well as the binary releases from Travis and Appveyor. We then host these releases on the Neuroconductor website. These downloads are stable in time and will not be changed until the next release. These downloads are also logged to show the activity/amount of use for each package of this release. To install the release, you would use:

source("https://neuroconductor.org/neurocLite.R")
neuro_install(c("fslr", "neurohcp"), release = "release")

See the release_repo argument for how to specify which release to use.

neurocLite: an alias for neuro_install

As Bioconductor uses the biocLite function to install packages, we have created a duplicate of neuro_install, called neurocLite, for ease of use for those users accustomed to Bioconductor. The same command could have been executed as follows:

source("https://neuroconductor.org/neurocLite.R")
neurocLite(c("fslr", "neurohcp"))

Installing Neuroconductor Packages without upgrading dependencies

The neurocLite/neuro_install functions depend on devtools::install_github, which will upgrade dependencies by default, which is recommended. If you would like to install a package, but not upgrade the dependencies (missing dependencies will still be installed), you can set the upgrade_dependencies argument to FALSE:

neurocLite(c("fslr", "neurohcp"), upgrade_dependencies = FALSE)

Installing and starting R

  1. Download the most recent version of R from https://cran.r-project.org/. There are detailed instructions on the R website as well as the specific R installation for the platform you are using, typically Linux, OSX, and Windows.

  2. Start R; we recommend using R through RStudio. You can start R using RStudio (Windows, OSX, Linux), typing “R” at in a terminal (Linux or OSX), or using the R application either by double-clicking on the R application (Windows and OSX).

  3. For learning R, there are many resources such as Try-R at codeschool and DataCamp.

Packages not available on Neuroconductor

If a package is not in the Neuroconductor list of packages, then it is not located on the Neuroconductor Github. Therefore, when installing, you’ll get the following error:

Error in neuro_install(...) : 
  Package(s) PACKAGE_TRIED_TO_INSTALL are not in neuroconductor

Once a package is located on the list of packages, then it will be available to install.

Session Info

devtools::session_info()
## ─ Session info ───────────────────────────────────────────────────────────────
##  setting  value                       
##  version  R version 4.0.2 (2020-06-22)
##  os       macOS Catalina 10.15.7      
##  system   x86_64, darwin17.0          
##  ui       X11                         
##  language (EN)                        
##  collate  en_US.UTF-8                 
##  ctype    en_US.UTF-8                 
##  tz       America/New_York            
##  date     2021-02-18                  
## 
## ─ Packages ───────────────────────────────────────────────────────────────────
##  package      * version   date       lib
##  abind          1.4-5     2016-07-21 [2]
##  animation    * 2.6       2018-12-11 [2]
##  ANTsR        * 0.5.7.5   2021-02-16 [1]
##  ANTsRCore    * 0.7.4.9   2021-02-16 [1]
##  assertthat     0.2.1     2019-03-21 [2]
##  base64enc      0.1-3     2015-07-28 [2]
##  bitops         1.0-6     2013-08-17 [2]
##  cachem         1.0.4     2021-02-13 [1]
##  callr          3.5.1     2020-10-13 [1]
##  cli            2.3.0     2021-01-31 [1]
##  colorout     * 1.2-2     2020-06-01 [2]
##  colorspace     2.0-0     2020-11-11 [1]
##  crayon         1.4.1     2021-02-08 [1]
##  DBI            1.1.1     2021-01-15 [1]
##  desc           1.2.0     2020-06-01 [2]
##  devtools     * 2.3.2     2020-09-18 [1]
##  digest         0.6.27    2020-10-24 [1]
##  dplyr        * 1.0.4     2021-02-02 [1]
##  ellipsis       0.3.1     2020-05-15 [2]
##  evaluate       0.14      2019-05-28 [2]
##  EveTemplate  * 1.0.0     2020-06-01 [2]
##  extrantsr    * 3.9.13.1  2020-09-03 [2]
##  fastmap        1.1.0     2021-01-25 [1]
##  fs             1.5.0     2020-07-31 [2]
##  fslr         * 2.25.0    2021-02-16 [1]
##  generics       0.1.0     2020-10-31 [1]
##  ggplot2      * 3.3.3     2020-12-30 [1]
##  git2r          0.28.0    2021-01-11 [1]
##  glue           1.4.2     2020-08-27 [1]
##  gtable         0.3.0     2019-03-25 [2]
##  htmltools      0.5.1.1   2021-01-22 [1]
##  httr           1.4.2     2020-07-20 [2]
##  ITKR           0.5.3.3.0 2021-02-15 [1]
##  kirby21.base * 1.7.4     2020-10-01 [1]
##  kirby21.fmri * 1.7.0     2018-08-13 [2]
##  kirby21.t1   * 1.7.3.2   2021-01-09 [1]
##  knitr        * 1.31      2021-01-27 [1]
##  lattice        0.20-41   2020-04-02 [2]
##  lifecycle      1.0.0     2021-02-15 [1]
##  magrittr       2.0.1     2020-11-17 [1]
##  matlabr      * 1.6.0     2020-07-01 [2]
##  Matrix         1.3-2     2021-01-06 [1]
##  matrixStats  * 0.58.0    2021-01-29 [1]
##  memoise        2.0.0     2021-01-26 [1]
##  mgcv           1.8-33    2020-08-27 [1]
##  munsell        0.5.0     2018-06-12 [2]
##  neurobase    * 1.31.0    2020-10-07 [1]
##  neurohcp     * 0.9.0     2021-02-18 [1]
##  nlme           3.1-152   2021-02-04 [1]
##  oro.nifti    * 0.11.0    2020-09-04 [2]
##  pillar         1.4.7     2020-11-20 [1]
##  pkgbuild       1.2.0     2020-12-15 [1]
##  pkgconfig      2.0.3     2019-09-22 [2]
##  pkgload        1.1.0     2020-05-29 [2]
##  plyr           1.8.6     2020-03-03 [2]
##  prettyunits    1.1.1     2020-01-24 [2]
##  processx       3.4.5     2020-11-30 [1]
##  ps             1.5.0     2020-12-05 [1]
##  purrr          0.3.4     2020-04-17 [2]
##  R.matlab       3.6.2     2018-09-27 [2]
##  R.methodsS3  * 1.8.1     2020-08-26 [1]
##  R.oo         * 1.24.0    2020-08-26 [1]
##  R.utils      * 2.10.1    2020-08-26 [1]
##  R6             2.5.0     2020-10-28 [1]
##  rcamino      * 0.6.4     2020-06-01 [2]
##  RColorBrewer * 1.1-2     2014-12-07 [2]
##  Rcpp           1.0.6     2021-01-15 [1]
##  RcppEigen      0.3.3.9.1 2020-12-17 [1]
##  remotes        2.2.0     2020-07-21 [2]
##  reshape2     * 1.4.4     2020-04-09 [2]
##  rlang          0.4.10    2020-12-30 [1]
##  rmarkdown    * 2.6       2020-12-14 [1]
##  RNifti         1.3.0     2020-12-04 [1]
##  rprojroot      2.0.2     2020-11-15 [1]
##  rstudioapi     0.13      2020-11-12 [1]
##  scales         1.1.1     2020-05-11 [2]
##  sessioninfo    1.1.1     2018-11-05 [2]
##  spm12r       * 2.8.2     2021-01-11 [1]
##  stapler        0.7.2     2020-07-09 [2]
##  stringi        1.5.3     2020-09-09 [1]
##  stringr      * 1.4.0     2019-02-10 [2]
##  testthat       3.0.2     2021-02-14 [1]
##  tibble         3.0.6     2021-01-29 [1]
##  tidyselect     1.1.0     2020-05-11 [2]
##  usethis      * 2.0.1     2021-02-10 [1]
##  vctrs          0.3.6     2020-12-17 [1]
##  WhiteStripe    2.3.2     2019-10-01 [2]
##  withr          2.4.1     2021-01-26 [1]
##  xfun           0.21      2021-02-10 [1]
##  yaml         * 2.2.1     2020-02-01 [2]
##  zoo          * 1.8-8     2020-05-02 [2]
##  source                                  
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  Github (ANTsX/ANTsR@4abee8d)            
##  Github (ANTsX/ANTsRCore@ddf445b)        
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  Github (jalvesaq/colorout@726d681)      
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  Github (muschellij2/desc@b0c374f)       
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  Github (muschellij2/EveTemplate@ed54115)
##  Github (muschellij2/extrantsr@00c75ad)  
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  local                                   
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  Github (ropensci/git2r@4e342ca)         
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  Github (stnava/ITKR@ea0ac19)            
##  local                                   
##  CRAN (R 4.0.0)                          
##  local                                   
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  local                                   
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  local                                   
##  local                                   
##  CRAN (R 4.0.2)                          
##  local                                   
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  Github (muschellij2/rcamino@6f9ba9f)    
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
##  local                                   
##  Github (muschellij2/stapler@79e23d2)    
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.2)                          
##  CRAN (R 4.0.0)                          
##  CRAN (R 4.0.0)                          
## 
## [1] /Users/johnmuschelli/Library/R/4.0/library
## [2] /Library/Frameworks/R.framework/Versions/4.0/Resources/library

References