| normality_test_t | R Documentation |
Test normality of a variable within two groups using Shapiro-Wilk on raw, square-root, and log10 transforms (for t-test context).
normality_test_t(df, variable_name, group, group_1, group_2)
df |
A data frame. |
variable_name |
Name of the numeric variable column (string). |
group |
<['data-masking'][dplyr::dplyr_data_masking]> The grouping column. |
group_1 |
Value identifying the first group. |
group_2 |
Value identifying the second group. |
A tibble with Shapiro-Wilk p-values for each group × transformation combination.
df <- data.frame(
grp = c("A","A","A","B","B","B"),
val = c(1.1, 2.0, 1.5, 4.2, 3.8, 4.5)
)
normality_test_t(df, "val", grp, "A", "B")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.