# \donttest{
if (rlang::is_installed(pkg = c("broom"))) {
npx_df <- npx_data1 |>
dplyr::filter(
!grepl(
pattern = "control",
x = .data[["SampleID"]],
ignore.case = TRUE
)
)
# Mann-Whitney U Test
wilcox_results <- OlinkAnalyze::olink_wilcox(
df = npx_df,
variable = "Treatment",
alternative = "two.sided"
)
# Paired Mann-Whitney U Test
wilcox_paired_results <- npx_df |>
dplyr::filter(
.data[["Time"]] %in% c("Baseline", "Week.6")
) |>
OlinkAnalyze::olink_wilcox(
variable = "Time",
pair_id = "Subject"
)
}
# }
Run the code above in your browser using DataLab