Description Usage Arguments Value Author(s) Examples
Reorder the layers of one dimension
1 |
table |
A sample of data with dimensions >=1, can be a matrix, an array or a table. |
summary |
A summary based on which we order within a dimension, can be functions in R or self-defined functions. |
dim |
Which dimension do we want to order. |
decreasing |
The order type, decreasing or increasing. |
The reordered table.
R. Wayne Oldford and Xiaomei Yu
1 2 3 4 5 6 7 8 9 10 11 12 13 | table2<-c(97.62,92.24,100.90,90.39,48.29,42.31,49.98,39.09,75.23,75.16,100.11,74.23,49.69,57.21,80.19,51.09)
table2 <- matrix(table2, nrow=4,byrow=TRUE,dimnames=list(c("North" ,"South","East","West"),c("Q1","Q2","Q3","Q4")))
table2
orderDim(table2, dim=1)
UCBAdmissions
orderDim(UCBAdmissions, dim=2)
HairEyeColor
orderDim(UCBAdmissions, dim=3)
Titanic
orderDim(Titanic, dim=3)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.