order_samples() takes a data frame and reorders the rows by
the contents of a specified column.
order_samples(sample_df, sample_ref = "sample_ref")
A data frame containing the rows to be sorted.
A character vector with a single element. This must be the
name of the column containing elements by which you wish to reorder the
rows. Defaults to "sample_ref" for ease of use with
Ordering is done using function
order(), which has its own particular
methods for ordering character vectors. Numeric sample reference codes stored
as characters are first coerced to numeric so they can be sorted sequentially,
if doing so does not produce
A data frame with rows reordered by the contents of the specified column. Rownames are overwritten with a simple sequence of numbers.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.