| imed_describe | R Documentation |
Descriptive statistics for a guarded analysis set
imed_describe(x, value = "Mean", group = NULL)
x |
An 'imed_db', or a measurement-level data frame such as the output of 'imed_analysis_set()'. The comparability guard is applied, so the records must belong to one compatible comparability class. |
value |
Name of the numeric measurement field to summarise (default '"Mean"'). |
group |
Optional grouping field (unquoted or quoted name). |
A 'tibble' with the columns 'n' (number of finite values), 'mean', 'sd', 'median', 'q1', 'q3', 'min' and 'max'. If 'group' is supplied there is one row per group, with the grouping field as the first column.
toy <- data.frame(
Study_ID = paste0("S", 1:12),
Comparability_Class = "CLASS_A",
Reported_Unit = "items/L",
Metric_Type = "Abundance",
Strict_Synthesis_Eligibility = "YES",
Group = rep(c("g1", "g2"), 6),
Mean = c(2.1, 3.4, 1.8, 4.0, 2.9, 3.1, 2.4, 3.8, 1.9, 3.3, 2.7, 4.2),
SD = rep(c(0.6, 0.9), 6),
N = rep(c(10, 12, 8), 4)
)
imed_describe(toy)
imed_describe(toy, group = "Group")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.