Nothing
context("outliers")
test_that("outliers.R", {
data("stackloss")
stack_lm <- lm(stack.loss ~ ., data = stackloss)
stack_outliers <- Bayes.outlier(stack_lm, k = 3)
expect_null(plot(stack_outliers$prob.outlier, type = "h",
ylab = "Posterior Probability"))
# adjust for sample size for calculating prior prob that a
# a case is an outlier
stack_outliers <- Bayes.outlier(stack_lm, prior.prob = 0.95)
#' # cases where posterior probability exceeds prior probability
expect_length(which(stack_outliers$prob.outlier >
stack_outliers$prior.prob),2)
expect_error(stack_outliers <- Bayes.outlier(stack_lm))
})
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.