morder function returns a permutation of row indices which can be used
to rearrangea an object
according to the values in the specified columns (a multi-column ordering).
mpermute function actually
reorders the rows of a
matrix based on
an order vector or a desired ordering on a set of columns.
The columns of
for controlling the treatment of
logical. Should the sort order be increasing or decreasing?
A vector specifying the reordering of rows, i.e. the result of a call to
optional parameters to pass to
morder function behaves similar to
a permutation of
1:nrow(x) which rearranges objects according to the
values in the specified columns. However,
big.matrix or an R
matrix (with numeric type) and a set of
cols) with which to determine the ordering;
not incur the same memory overhead required by
order, and runs more quickly.
mpermute function changes the row ordering of a
matrix based on a vector
order or an ordering based
on a set of columns specifed by
cols. It should be noted that
this function has side-effects, that is
x is changed when this
function is called.
morder returns an ordering vector.
mpermute returns nothing but does change the contents of
This type of a side-effect is generally frowned upon in R, but we “break”
the rules here to avoid memory overhead and improve performance.
Michael J. Kane <firstname.lastname@example.org>
1 2 3 4 5 6 7
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.