Nothing
test_that("calc_mode_date returns the correct mode date", {
result <- calc_mode_date(
x = c("2024-01-01", "2024-01-01", "2024-01-02", "2024-01-03")
)
expect_equal(result, as.Date("2024-01-01"))
})
test_that("calc_mode_date returns the mean of modes date when there are multiple modes", {
result <- calc_mode_date(
x = c("2024-01-01", "2024-01-01", "2024-01-03", "2024-01-03")
)
expect_equal(result, as.Date("2024-01-02"))
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.