Breaking changes in preparation for 1.0.0 release:
* The `hypothesis` argument no longer accepts strings like "reference" or "pairwise". Use the formula interface instead: `hypothesis= ~reference`
* The default `type` is now "survival" for models of class `coxph`, `flexsurvreg`, and `coxph_weightit`.
* `p_adjust` argument deprecated because of name-matching conflict with `p` argument in quantile regression and others. The recommended workflow is now to pass the object to the `hypotheses()` function and use its `multcomp` argument.
* Removed long deprecated functions from the code base. These functions were already raising errors: `marginaleffects`, `meffects`, `marginal_means`, `deltamethod`, `datagridcf`.
* `newdata="marginalmeans"` was changed to `newdata="balanced"` several releases ago, but backward compatibility was maintained. This shortcut is no longer available at all.
New:
* The `hypothesis` argument is more flexible. Thanks to mattansb for requests, testing, and documentation.
- `hypothesis = ratio ~ meandev | groupid`
- `hypothesis = ~ poly | groupid`
- `hypothesis = ~ helmert | groupid`
- `hypothesis = ~ trt_vs_ctrl | groupid`
- `hypothesis = ~ I(foo(x)) | groupid`
- `hypothesis = ~ I(\(x) c(a = x[1], b = mean(x[2:length(x))))`
* New function `get_dataset()` to download example data frames from the https://marginaleffects.com website. Thanks to bshor for the feature request.
* New `multcomp` argument for the `hypotheses()` function.
* `hypotheses()` inherits the `conf_level` from `marginaleffects` objects when available. Otherwise, the default remains 0.95.
* More informative warning for `lme4` and `glmmTMB` models with `re.form=NULL`
* `df.residual()` methods tries to call `stats::df.residual()` on the "model" attribute. If that fails or returns `NULL`, we return `Inf`.
* Column names are no longer printed by default.
* Allow multiple sequential `hypotheses()` calls. Issue 1316.
* Better parameter name labels in `get_draws()`. Thanks to andymilne for feature request 1318.
* `rvar` column from `get_draws()` is now printed by default.
* Matrix columns with 1 column are supported. Fixes errors when a variable was transformed by `scale()`, for example. Thanks to barryrowlingson for the report.
* Much faster inference with `inferences(method="boot")`. Thanks to nremenyi for issue 1352.
* `hypothesis=~pairwise` only errors when there are more than 300 comparisons. `options(marginaleffects_safe=FALSE)` to disable this check.
Bugs:
* Version 0.24.0 accidentally removed the "contrast" column from the output object in calls with only one focal predictor. This column is reinstated.
* Reinstate some attributes lost with `marginaleffects_lean` but necessary for printing.
* Encoding issue in bayesian models with `by`. Thanks to Koalha for report 1290.
* Retain necessary attribute information to ensure that "lean" return objects still print correctly 1295.
* Indexing problem with `avg_comparisons(by=data.frame())` and `avg_slopes(by=data.frame())`. Thanks to andymilne for report 1313.
* `hypotheses(p, hypothesis=~reference)` did not work for some `p` objects. Issue 1310.
* `gray` is respected for the `points` argument in `plot_*()`
* `hypotheses(x, joint=1:2)` did not work when `x` was a `marginaleffects` object. Thanks to mattansb for report 1340