Description Usage Arguments Details Value See Also Examples
Calculates an order statistic for each row (column) of a matrix-like object.
1 2 3 4 5 |
x |
An NxK matrix-like object. |
rows |
A |
cols |
A |
which |
An integer index in [1,K] ([1,N]) indicating which order statistic to be returned |
na.rm |
If TRUE, NAs are excluded first, otherwise not. |
The S4 methods for x
of type matrix
,
array
, or numeric
call
matrixStats::rowOrderStats
/ matrixStats::colOrderStats
.
Returns a numeric
vector
of length N (K).
matrixStats::rowOrderStats()
and
matrixStats::colOrderStats()
which are used when the input is a matrix
or numeric
vector.
1 2 3 4 5 6 7 8 9 |
Loading required package: MatrixGenerics
Loading required package: matrixStats
Attaching package: ‘MatrixGenerics’
The following objects are masked from ‘package:matrixStats’:
colAlls, colAnyNAs, colAnys, colAvgsPerRowSet, colCollapse,
colCounts, colCummaxs, colCummins, colCumprods, colCumsums,
colDiffs, colIQRDiffs, colIQRs, colLogSumExps, colMadDiffs,
colMads, colMaxs, colMeans2, colMedians, colMins, colOrderStats,
colProds, colQuantiles, colRanges, colRanks, colSdDiffs, colSds,
colSums2, colTabulates, colVarDiffs, colVars, colWeightedMads,
colWeightedMeans, colWeightedMedians, colWeightedSds,
colWeightedVars, rowAlls, rowAnyNAs, rowAnys, rowAvgsPerColSet,
rowCollapse, rowCounts, rowCummaxs, rowCummins, rowCumprods,
rowCumsums, rowDiffs, rowIQRDiffs, rowIQRs, rowLogSumExps,
rowMadDiffs, rowMads, rowMaxs, rowMeans2, rowMedians, rowMins,
rowOrderStats, rowProds, rowQuantiles, rowRanges, rowRanks,
rowSdDiffs, rowSds, rowSums2, rowTabulates, rowVarDiffs, rowVars,
rowWeightedMads, rowWeightedMeans, rowWeightedMedians,
rowWeightedSds, rowWeightedVars
[,1] [,2] [,3]
[1,] 0.1583615 0.2704270 1.2541778
[2,] 2.0000000 1.2665525 -1.4995291
[3,] 0.6899651 -0.5106760 Inf
[4,] 0.0000000 0.4842335 -1.3416163
[5,] -0.8845643 -1.1153721 -0.6899365
[1] 0.1583615 -1.4995291 -0.5106760 -1.3416163 -1.1153721
[1] 0.1583615 0.2704270 -0.6899365
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.