orderCompletely | R Documentation |
Completely order all rows in a data.frame.
orderCompletely(observed)
observed |
a data.frame holding ordered factors in every column |
the sorted order of the rows
df <- as.data.frame(matrix(c(sample.int(2, 30, replace=TRUE)), 10, 3))
mask <- matrix(c(sample.int(3, 30, replace=TRUE)), 10, 3) == 1
df[mask] <- NA
df[orderCompletely(df),]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.