Description Usage Arguments Details Value See Also Examples
reorder.array
reorders an array along a specified
dimension according given names, indices or results of
a function applied.
1 2 3 4 |
x |
An array |
dim |
An integer specifying the dimension along which |
names |
A character vector |
indices |
A numeric vector |
FUN |
A function that can be used in |
... |
further arguments, ignored. |
Typical usages are
1 2 3 4 |
The result of rename(x,dim,names)
is x
reordered such that dimnames(x)[[dim]]
is equal to
the concatenation of those elements of names
that are in dimnames(x)[[dim]]
and the remaining elements
of dimnames(x)[[dim]]
.
The result of rename(x,dim,indices)
is x
reordered along dim
according to indices
.
The result of rename(x,dim,FUN)
is x
reordered along dim
according to order(apply(x,dim,FUN))
.
The reordered object x
.
The default method of reorder
in package stats
.
1 2 3 4 5 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.