renderFeatureStatsDataTable.Rd
We often want to display an interactive table of feature level statistics for all features. This function is a convenience wrapper to do that.
A `SparrowResult` or `data.frame` of feature level statistics. When `x` is a `SparrowResult`, the `logFC` feature level statistics will be extracted for display.
A character vector that specifies the subset of `feature_id`'s to display from `x`. If `NULL` (default), all of `x` will be used.
number of digits to round the numeric columns to
the columns from `x` to use. If `missing`, then only `c('symbol', 'feature_id', 'logFC', 'pval', 'padj', order.by)` will be used. If explicitly set to `NULL` all columns will be used.
A function that receives the data.frame of statistics to be rendered and transforms one of its columns into a hyperlink for further reference. Refer to [ncbi.entrez.link()] as an example.
name of the column to order the geneset stats by
do we order the table by the values in `order.by` in `"desc"`-ending, or `"asc"`-ending order (default: `"desc"`)
passed to [DT::datatable()]
parameter passed as an option to [DT::datatable()] that specifies how long the table can be per page.
A [DT::datatable()] of feature statistics
sr <- sparrow::exampleSparrowResult()
lfc <- sparrow::logFC(sr)
if (interactive()) {
renderFeatureStatsDataTable(sr, sample(lfc$feature_id, 200),
feature.link.fn = ncbi.entrez.link)
}