diff --git a/R/strategy_.R b/R/strategy_.R
index 0b5b718..5e5ec6f 100644
--- a/R/strategy_.R
+++ b/R/strategy_.R
@@ -102,6 +102,16 @@ strategy_maic <- function(formula = NULL,
}
}
}
+ # Ensure MAIC uses an unadjusted outcome model to prevent estimating conditional effects.
+ resp_var <- all.vars(outcome_model)[1]
+ out_vars <- all.vars(outcome_model)
+
+ if (length(setdiff(out_vars, c(resp_var, trt_var))) > 0) {
+ if (verbatim) {
+ warning("Covariates detected in the MAIC outcome model. To ensure the estimation of compatible marginal treatment effects, MAIC requires an unadjusted outcome model. The outcome model is being automatically overridden to '", resp_var, " ~ ", trt_var, "'.", call. = FALSE)
+ }
+ outcome_model <- as.formula(paste(resp_var, "~", trt_var))
+ }
check_formula(outcome_model, trt_var)
diff --git a/README.md b/README.md
index 52edc0e..4c66977 100644
--- a/README.md
+++ b/README.md
@@ -10,8 +10,7 @@
[](https://github.com/StatisticsHealthEconomics/outstandR/actions/workflows/R-CMD-check.yaml)
[](https://www.gnu.org/licenses/gpl-3.0)
-[](https://statisticshealtheconomics.r-universe.dev/outstandR)
+
[](https://CRAN.R-project.org/package=outstandR)
[](https://codecov.io/gh/StatisticsHealthEconomics/outstandR)
diff --git a/_pkgdown.yml b/_pkgdown.yml
index 4b6b2ff..7b4f1ac 100644
--- a/_pkgdown.yml
+++ b/_pkgdown.yml
@@ -83,14 +83,17 @@ reference:
contents:
- strategy-class
-# articles:
-# - title: "Binary outcome data example"
-# contents:
-# - "Binary_outcome_example"
-# - title: "Continuous outcome data example"
-# contents:
-# - "Continuous_outcome_example"
-# - title: "Count outcome data example"
-# contents:
-# - "Count_outcome_example"
+articles:
+- title: "Binary outcome data example"
+ contents:
+ - "Binary_outcome_example"
+- title: "Continuous outcome data example"
+ contents:
+ - "Continuous_outcome_example"
+- title: "Count outcome data example"
+ contents:
+ - "Count_outcome_example"
+- title: "Developer Guides"
+ contents:
+ - "articles/adding-a-new-strategy"
diff --git a/badge.svg b/badge.svg
new file mode 100644
index 0000000..fe9d5de
--- /dev/null
+++ b/badge.svg
@@ -0,0 +1,22 @@
+
\ No newline at end of file
diff --git a/docs/404.html b/docs/404.html
index 553eed2..90580a3 100644
--- a/docs/404.html
+++ b/docs/404.html
@@ -12,8 +12,8 @@
-
-
+
+
diff --git a/docs/GEMINI.html b/docs/GEMINI.html
index 8dc14f5..d9bda19 100644
--- a/docs/GEMINI.html
+++ b/docs/GEMINI.html
@@ -1,5 +1,5 @@
-