Learn R Programming

matrixStats (version 0.12.2)

rowRanges: Gets the range of values in each row (column) of a matrix

Description

Gets the range of values in each row (column) of a matrix.

Usage

rowRanges(x, na.rm=FALSE, ...)
  colRanges(x, na.rm=FALSE, ...)
  rowMins(x, na.rm=FALSE, dim.=dim(x), ...)
  colMins(x, na.rm=FALSE, dim.=dim(x), ...)
  rowMaxs(x, na.rm=FALSE, dim.=dim(x), ...)
  colMaxs(x, na.rm=FALSE, dim.=dim(x), ...)

Arguments

x
na.rm
If TRUE, NAs are excluded first, otherwise not.
dim.
An integer vector of length two specifying the dimension of x, also when not a matr
...
Not used.

Value

  • rowRanges() (colRanges()) returns a numeric Nx2 (Kx2) matrix, where N (K) is the number of rows (columns) for which the ranges are calculated.

    rowMins()/rowMaxs() (colMins()/colMaxs()) returns a numeric vector of length N (K).

See Also

rowOrderStats() and pmin.int().