% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/validateIndices.R
\name{validateIndices}
\alias{validateIndices}
\title{Validate indices}
\usage{
validateIndices(idxs = NULL, maxIdx, allowOutOfBound = TRUE)
}
\arguments{
\item{idxs}{A \code{\link[base]{integer}} \code{\link[base]{vector}}. If
\code{\link[base]{NULL}}, all indices are considered.}

\item{maxIdx}{The possible max index.}

\item{allowOutOfBound}{Allow positive out of bound to indicate
\code{\link[base]{NA}}.}
}
\value{
Returns a validated integers list indicating the indices.
}
\description{
Computes validated positive indices from given indices.
}
\examples{
idxs <- validateIndices(c(-4, 0, -3, -1), 5)  # [2, 5]

idxs <- validateIndices(c(4, 4, 8, 2, 3), 8)  # [4, 4, 8, 2, 3]
}
\keyword{internal}
