# \donttest{
set.seed(2026)
N = 500
test_data <-
data.frame(x1 = rnorm(N),
x2 = rnorm(N),
x3 = letters[1:5])
test_data$outcome <-
rnorm(N,-1 + test_data$x1 + 2 * (test_data$x3 %in% c("d","e")) )
fit_full <-
lm_b(outcome ~ x1 + x2 + x3,
data = test_data)
fit_no_x1 <-
lm_b(outcome ~ x2 + x3,
data = test_data)
fit_no_x2 <-
lm_b(outcome ~ x1 + x3,
data = test_data)
frac_bayes_factors(fit_full,
fit_no_x1)
frac_bayes_factors(fit_full,
fit_no_x2)
# }
Run the code above in your browser using DataLab