Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixing docs and some suggests #413

Merged
merged 7 commits into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -29,3 +29,4 @@ R/connectedThresholdImage.R
Dockerfile
code_of_conduct.md
^data-raw$
^Makefile$
10 changes: 10 additions & 0 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -53,7 +53,17 @@ jobs:
${{ runner.os }}-${{ hashFiles('.github/R-version') }}-1
${{ runner.os }}-${{ hashFiles('.github/R-version') }}
${{ runner.os }}-

- name: Build HDF5 - OSX
if: runner.os == 'macOS'
run: |
brew install hdf5

- name: Build HDF5 - LINUX
if: runner.os == 'Linux'
run: |
sudo apt-get install -y libhdf5-dev

- name: Install dependencies
run: |
remotes::install_deps(dependencies = TRUE)
7 changes: 5 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -43,7 +43,6 @@ Suggests:
caret,
cluster,
corpcor,
dplyr,
e1071,
fastICA,
fpc,
@@ -79,7 +78,11 @@ Suggests:
tsne,
viridis,
xgboost,
FNN
FNN,
gridExtra,
hdf5r,
salad,
reshape2
LazyData: TRUE
Remotes: ANTsX/ANTsRCore
VignetteBuilder: knitr
2 changes: 1 addition & 1 deletion R/antsApplyTransforms.R
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@
#' @param transformlist character vector of transforms generated by antsRegistration where
#' each transform is a filename.
#' @param interpolator Choice of interpolator. Supports partial matching.
#' \itemize{
#' \describe{
#' \item{linear}{}
#' \item{nearestNeighbor}{}
#' \item{multiLabel}{ for label images but genericlabel is preferred}
2 changes: 1 addition & 1 deletion R/antsImageHeaderInfo.R
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@
#' antsImageHeaderInfo(getANTsRData("r16"))
#'
#' @return outputs a list containing:
#' \itemize{
#' \describe{
#' \item{pixelclass: }{Type of pixel (scalar, vector, etc).}
#' \item{pixeltype: }{Type of pixel values (int, float, etc).}
#' \item{nDimensions: }{Number of image dimensions.}
2 changes: 1 addition & 1 deletion R/antsMotionCalculation.R
Original file line number Diff line number Diff line change
@@ -27,7 +27,7 @@
#' @param ... additional argument to \code{\link{.motion_correction}}
#'
#' @return List containing:
#' \itemize{
#' \describe{
#' \item{moco_img}{ Motion corrected time-series image.}
#' \item{moco_params}{ Data frame of translation parameters.}
#' \item{moco_avg_img}{ Average motion-corrected image.}
4 changes: 2 additions & 2 deletions R/antsRegistration.R
Original file line number Diff line number Diff line change
@@ -53,7 +53,7 @@
#' @param ... additional options see antsRegistration in ANTs
#' @details
#' typeofTransform can be one of:
#' \itemize{
#' \describe{
#' \item{"Translation": }{Translation transformation.}
#' \item{"Rigid": }{Rigid transformation: Only rotation and translation.}
#' \item{"Similarity": }{Similarity transformation: scaling, rotation and
@@ -111,7 +111,7 @@
#' \item{"antsRegistrationSyNQuickRepro[x]":}{quick reproducible registration. x options as above.}
#' }
#' @return outputs a list containing:
#' \itemize{
#' \describe{
#' \item{warpedmovout: }{Moving image warped to space of fixed image.}
#' \item{warpedfixout: }{Fixed image warped to space of moving image.}
#' \item{fwdtransforms: }{Transforms to move from moving to fixed image.}
6 changes: 3 additions & 3 deletions R/antsrMetric_class.R
Original file line number Diff line number Diff line change
@@ -59,7 +59,7 @@ setMethod(f = "initialize", signature(.Object = "antsrMetric"), definition = fun
#' @param fixed the fixed antsImage
#' @param moving the moving antsImage
#' @param type image metric to calculate
#' \itemize{
#' \describe{
#' \item{MeanSquares}{}
#' \item{Correlation}{}
#' \item{ANTSNeighborhoodCorrelation}{}
@@ -72,7 +72,7 @@ setMethod(f = "initialize", signature(.Object = "antsrMetric"), definition = fun
#' @param fixed.mask mask for the fixed image
#' @param moving.mask mask for the moving image
#' @param sampling.strategy sampling strategy, default if full sampling
#' \itemize{
#' \describe{
#' \item{none}{Full sampling}
#' \item{random}{}
#' \item{regular}{}
@@ -283,7 +283,7 @@ antsrMetricSetRadius <- function(metric, radius) {
#' @description set image sampling strategy and rate
#' @param metric an 'antsrMetric'
#' @param sampling.strategy sampling strategy, default if full sampling
#' \itemize{
#' \describe{
#' \item{none}{Full sampling}
#' \item{random}{}
#' \item{regular}{}
2 changes: 1 addition & 1 deletion R/antsrMotionCalculation.R
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@
#' for discussion. If \code{NULL}, will not set anything.
#' @param ... extra parameters passed to antsRegistration
#' @return List containing:
#' \itemize{
#' \describe{
#' \item{moco_img}{ Motion corrected time-series image.}
#' \item{moco_params}{ Data frame of translation parameters.}
#' \item{moco_avg_img}{ Average motion-corrected image.}
2 changes: 1 addition & 1 deletion R/antsrTransform_class.R
Original file line number Diff line number Diff line change
@@ -59,7 +59,7 @@ setMethod(f = "initialize", signature(.Object = "antsrTransform"), definition =
#' @title createAntsrTransform
#' @description Create and initialize an antsrTransform
#' @param type type of transform
#' \itemize{
#' \describe{
#' \item{AffineTransform}{}
#' \item{CenteredAffineTransform}{}
#' \item{Euler2DTransform}{}
4 changes: 2 additions & 2 deletions R/aslAveraging.R
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@
#'
#' @details
#' Two major types of methods are available for ASL signal averaging:
#' \itemize{
#' \describe{
#' \item{Subtraction}{: All the subtraction methods are based on subtracting
#' the tag from control images and averaging the result. \code{simple}
#' subtracts adjacent tag and control images. The other methods use
@@ -29,7 +29,7 @@
#' similar perfusion values.}
#' }
#' For \code{bayesian}, two more arguments are required:
#' \itemize{
#' \describe{
#' \item{segmentation}{: a segmentation image}
#' \item{tissuelist}{: a list of tissue probability images}
#' }
6 changes: 3 additions & 3 deletions R/aslCensoring.R
Original file line number Diff line number Diff line change
@@ -10,12 +10,12 @@
#' @param ... Additional arguments to pass to censoring method. See \code{Details.}
#' @details \code{aslCensoring} is an interface to ASL timepoint censoring algorithms.
#' Three options are currently provided, with different additional arguments:
#' \enumerate{
#' \describe{
#' \item{\code{outlier}}{ Outlier rejection from Tan et al. This method rejects
#' volumes that are either far from the mean of the time-series or whose
#' standard deviation is far from the standard deviations of the individual volumes.
#' Accepts two additional arguments:
#' \itemize{
#' \describe{
#' \item{\code{sigma.mean}: }{how many standard
#' deviations the mean of the volume can be from the
#' mean of all the volumes before
@@ -27,7 +27,7 @@
#' }
#' \item{\code{robust}}{ Uses a robust regression approach to estimate volumes
#' with high leverage. Accepts three arguments:
#' \itemize{
#' \describe{
#' \item{\code{nuis}:}{ Nuisance regressors to use as covariates.}
#' \item{\code{robthresh}:}{ Threshold for weights on leverage estimates. Points
#' with weights under this value will be thrown out; defaults to 0.95.}
10 changes: 5 additions & 5 deletions R/euler.R
Original file line number Diff line number Diff line change
@@ -6,11 +6,11 @@
#' @param u statistical value (typically the maxima of a cluster or statistical field)
#' @param df degrees of freedom expressed as df = c(degrees of interest, degrees of error)
#' @param fieldType
#' \itemize{
#' \item{T: } {T-field}
#' \item{F: } {F-field}
#' \item{X: } {Chi-square field'}
#' \item{Z: } {Gaussian field}
#' \describe{
#' \item{T: }{T-field}
#' \item{F: }{F-field}
#' \item{X: }{Chi-square field'}
#' \item{Z: }{Gaussian field}
#' }
#' @return A vector of estimated euler characteristics for dimensions 0:D
#'
2 changes: 1 addition & 1 deletion R/fitBsplineObjectToScatteredData.R
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@
#' for the ITK filter \url{https://itk.org/Doxygen/html/classitk_1_1BSplineScatteredDataPointSetToImageFilter.html}.
#' This filter is flexible in the possible objects that can be approximated.
#' Possibilities include:
#' \itemize{
#' \describe{
#' \item{curve:}{1/2/3/4-D}
#' \item{surface:}{2-D surface in 3-D space (not available/templated)}
#' \item{scalar:}{2/3/4-D scalar field}
7 changes: 5 additions & 2 deletions R/getMask.R
Original file line number Diff line number Diff line change
@@ -3,8 +3,11 @@
#' Get a binary mask image from the given image after thresholding.
#'
#' If \code{cleanup} is \code{>0}, the following steps are applied
#' \enumerate{ \item Erosion with radius 2 voxels \item Retain largest
#' component \item Dilation with radius 1 voxel \item Morphological closing }
#' \enumerate{
#' \item Erosion with radius 2 voxels
#' \item Retain largest component
#' \item Dilation with radius 1 voxel \item Morphological closing
#' }
#'
#' These functions are available in \link{iMath}, see the operations
#' \dQuote{ME}, \dQuote{GetLargestComponent}, \dQuote{MD}, \dQuote{FillHoles}.
6 changes: 3 additions & 3 deletions R/getNeighborhood.R
Original file line number Diff line number Diff line change
@@ -8,7 +8,7 @@
#' @param physical.coordinates a logical indicating if voxel indices and
#' offsets should be in voxel or physical coordinates
#' @return a list
#' \itemize{
#' \describe{
#' \item{values}{numeric vector of values}
#' \item{indices}{matrix providing the coordinates for each value}
#' }
@@ -88,7 +88,7 @@ getNeighborhoodAtVoxel <- function(image, center, kernel, physical.coordinates =
#' center voxel) should be returned in addition to the value matrix (WIP)
#' @details
#' \code{boundary.condition} should be one of:
#' \itemize{
#' \describe{
#' \item{\code{NA}: }{Fill values with \code{NA}.}
#' \item{\code{image}: }{Use image value, even if not in mask.}
#' \item{\code{mean}: }{Use man of all non-\code{NA} values for that neighborhood.}
@@ -99,7 +99,7 @@ getNeighborhoodAtVoxel <- function(image, center, kernel, physical.coordinates =
#' is the size of the neighborhood and there is a column for each voxel
#'
#' if \code{spatial.info} is true, a list containing three matrices:
#' \itemize{
#' \describe{
#' \item{values: }{matrix of pixel values where the number of rows
#' is the size of the neighborhood and there is a column for each voxel.}
#' \item{indices: }{matrix providing the center coordinates for each neighborhood}
4 changes: 2 additions & 2 deletions R/imageSimilarity.R
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
#' @param fixed the fixed antsImage
#' @param moving the moving antsImage
#' @param type image metric to calculate
#' \itemize{
#' \describe{
#' \item{MeanSquares}{}
#' \item{Correlation}{}
#' \item{ANTSNeighborhoodCorrelation}{}
@@ -14,7 +14,7 @@
#' @param fixed.mask mask for the fixed image
#' @param moving.mask mask for the moving image
#' @param sampling.strategy sampling strategy, default if full sampling
#' \itemize{
#' \describe{
#' \item{none}{Full sampling}
#' \item{random}{}
#' \item{regular}{}
4 changes: 2 additions & 2 deletions R/labelImageRegistration.R
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@
#' @param randomSeed Definition for deformable registration.
#' @param verbose Print progress to the screen.
#' @return outputs a list containing:
#' \itemize{
#' \describe{
#' \item{fwdtransforms: }{Transforms to move from moving to fixed image.}
#' \item{invtransforms: }{Transforms to move from fixed to moving image.}
#' }
@@ -415,4 +415,4 @@ labelImageRegistration <- function( fixedLabelImages, movingLabelImages,

return( list( fwdtransforms = fwdtransforms,
invtransforms = invtransforms ) )
}
}
6 changes: 3 additions & 3 deletions R/morphology.R
Original file line number Diff line number Diff line change
@@ -5,21 +5,21 @@
#'
#' @param input input image
#' @param operation operation to apply
#' \itemize{
#' \describe{
#' \item{"close"}{ Morpholgical closing}
#' \item{"dilate"}{ Morpholgical dilation}
#' \item{"erode"}{ Morpholgical erosion}
#' \item{"open"}{ Morpholgical opening}
#' }
#' @param type type of morphology
#' \itemize{
#' \describe{
#' \item{"binary"}{ Binary operation on a single value}
#' \item{"grayscale"}{ Grayscale operations}
#' }
#' @param radius radius of structuring element
#' @param value value to operation on (type='binary' only)
#' @param shape shape of the structuring element ( type='binary' only )
#' \itemize{
#' \describe{
#' \item{"ball"}{ spherical structuring element}
#' \item{"box"}{ box shaped structuring element}
#' \item{"cross"}{ cross shaped structuring element}
Loading
Loading