From a19f0ee661bc82ea6cdefd7dba918023a24c549b Mon Sep 17 00:00:00 2001 From: Jon Clayden Date: Wed, 19 Jun 2024 18:16:08 +0100 Subject: [PATCH] Update documentation --- DESCRIPTION | 2 +- R/rgb.R | 9 +++++++-- man/rgbArray.Rd | 10 ++++++++-- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index f68fd72..5b91bea 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -25,5 +25,5 @@ License: GPL-2 URL: https://github.com/jonclayden/RNifti BugReports: https://github.com/jonclayden/RNifti/issues Encoding: UTF-8 -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.1 Roxygen: list(old_usage=TRUE) diff --git a/R/rgb.R b/R/rgb.R index ea0cc9a..3364be2 100644 --- a/R/rgb.R +++ b/R/rgb.R @@ -22,9 +22,14 @@ #' dimensions of \code{red} are used if this is \code{NULL}. #' @param ... For \code{rgbArray}, additional attributes to set on the result, #' such as \code{pixdim}. These are passed directly to -#' \code{\link{structure}}. For the \code{as.character} method, this argument -#' is ignored. +#' \code{\link{structure}}. For the indexing method, additional indices. +# For the \code{as.character} method, this argument is ignored. #' @param x An \code{rgbArray} object. +#' @param i,j Index vectors, which are passed to the \code{array} method. +#' @param drop Whether or not to drop unitary dimensions. \code{rgbArray} +#' objects currently always have a \code{dim} attribute, so if the result is +#' a vector it will have a remaining single-element dimension equal to its +#' length. #' @param flatten Logical value. If \code{FALSE}, the dimensions of \code{x} #' will be retained in the result. The default is \code{TRUE}, for #' consistency with the usual behaviour of \code{as.character}, which strips diff --git a/man/rgbArray.Rd b/man/rgbArray.Rd index 0a3f8f5..aa9d7c0 100644 --- a/man/rgbArray.Rd +++ b/man/rgbArray.Rd @@ -35,11 +35,17 @@ dimensions of \code{red} are used if this is \code{NULL}.} \item{...}{For \code{rgbArray}, additional attributes to set on the result, such as \code{pixdim}. These are passed directly to -\code{\link{structure}}. For the \code{as.character} method, this argument -is ignored.} +\code{\link{structure}}. For the indexing method, additional indices.} \item{x}{An \code{rgbArray} object.} +\item{i, j}{Index vectors, which are passed to the \code{array} method.} + +\item{drop}{Whether or not to drop unitary dimensions. \code{rgbArray} +objects currently always have a \code{dim} attribute, so if the result is +a vector it will have a remaining single-element dimension equal to its +length.} + \item{flatten}{Logical value. If \code{FALSE}, the dimensions of \code{x} will be retained in the result. The default is \code{TRUE}, for consistency with the usual behaviour of \code{as.character}, which strips