Skip to content

ANTsX/ANTsR

Repository files navigation

Advanced Normalization Tools in R

R-CMD-check Downloads Binder Contributor Covenant

ANTsR is an R package which wraps the well-established C++ biomedical image processing library ANTs. It includes efficient reading and writing of medical images, algorithms for registration, segmentation, and statistical learning, as well as functions to create publication-ready visualizations.

If you are looking to train deep learning models on your medical images in R, you might be interested in ANTsRNet which provides pre-trained models and utilities for training deep learning models on medical images.


Installation

The ANTsR package can be installed the pre-compiled binaries (fast) or from source. We are actively working on getting ANTsR onto a host like CRAN or BioConductor.

Pre-compiled binaries

The fastest way to install ANTsR is from pre-compiled binaries made available on the Releases Page. However, you must first install the ANTsRCore package, whose pre-compiled binaries are available on its own Releases Page. Download the relevant versions for both pacakges and run this from the command-line:

R CMD INSTALL ANTsRCore_*.tgz
R CMD INSTALL ANTsR_*.tgz

From source using devtools

To install ANTsR from source, you can use devtools to install the latest version of the code directly form GitHub. This should also automatically install the main dependencies like the ANTsRCore package.

devtools::install_github('ANTsX/ANTsR')

From source using R CMD INSTALL

Alternatively, you can clone and install ANTsR and its two main dependencies (ANTsRCore, ITKR) and then install them as you would traditional R source packages.

First, clone the repositories:

$ git clone https://github.com/stnava/ITKR.git
$ git clone https://github.com/ANTsX/ANTsRCore.git
$ git clone https://github.com/ANTsX/ANTsR.git

Install the package as follows:

$ R CMD INSTALL ITKR
$ R CMD INSTALL ANTsRCore
$ R CMD INSTALL ANTsR

Developer notes

Authors

Brian B. Avants (maintainer), Benjamin M. Kandel, Jeff T. Duda, Philip A. Cook, Nicholas J. Tustison

License

Apache License 2.0


Relevant links

ANTsR Instagram

DOI 10.17605/osf.io/bsq5v

Reference manual: ANTsR

Vignettes:

Wiki: Notes and work in progress examples

Package source: from github

Binaries: here

Windows installation option here

Suggested packages https://github.com/stnava/ANTsRDocker/blob/master/install.R


Research using ANTsR


Contributing

If you have a question or need help solving a problem, please create an issue on GitHub. If you want to contribute code or have a feature request, creating an issue on GitHub is also the best place to start.