Skip to content

Commit

Permalink
Merge pull request #157 from jacob-long/master
Browse files Browse the repository at this point in the history
Integrate recent package updates
  • Loading branch information
jacob-long authored Aug 9, 2024
2 parents 9679b41 + d8a3de4 commit be1e0bd
Show file tree
Hide file tree
Showing 103 changed files with 1,064 additions and 535 deletions.
2 changes: 1 addition & 1 deletion .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@
^CONTRIBUTING.md$
^\.github$
^\.vs$
^doc$
^Meta$
^make_hex\.R$
^hex\.png$
^LICENSE\.md$
^paper\.md$
^pkgdown$
^CRAN-SUBMISSION$
^doc$
18 changes: 18 additions & 0 deletions .github/workflows/recheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
on:
workflow_dispatch:
inputs:
which:
type: choice
description: Which dependents to check
options:
- strong
- most

name: Reverse dependency check

jobs:
revdep_check:
name: Reverse check ${{ inputs.which }} dependents
uses: r-devel/recheck/.github/workflows/recheck.yml@v1
with:
which: ${{ inputs.which }}
16 changes: 8 additions & 8 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,27 @@ License: GPL (>= 3)
Encoding: UTF-8
LazyData: true
Imports:
crayon,
cli,
generics,
broom,
broom.mixed,
ggplot2 (>= 3.4.0),
magrittr,
pander,
pkgconfig,
rlang (>= 0.3.0),
rlang,
sandwich,
tibble
Suggests:
boot,
broom,
broom.mixed,
huxtable (>= 3.0.0),
huxtable,
kableExtra,
lme4,
lmerTest,
MASS,
methods,
pbkrtest,
RColorBrewer,
sandwich,
scales,
survey,
weights,
Expand All @@ -47,8 +47,8 @@ Enhances:
brms,
quantreg,
rstanarm
RoxygenNote: 7.2.3
RoxygenNote: 7.3.2.9000
VignetteBuilder: knitr
Roxygen: list(markdown = TRUE)
Depends:
R (>= 3.5.0)
R (>= 3.6.0)
104 changes: 15 additions & 89 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -20,90 +20,6 @@ if (!nzchar(system.file(package = "interactions"))) {
if (!nzchar(system.file(package = "interactions"))) {
export(sim_slopes)
}

if (getRversion() >= "3.6.0") {
S3method(generics::tidy, glht)
} else {
export(tidy.glht)
}

if (getRversion() >= "3.6.0") {
S3method(generics::tidy, summary.glht)
} else {
export(tidy.summary.glht)
}

if (getRversion() >= "3.6.0") {
S3method(knitr::knit_print, summ.glm)
} else {
export(knit_print.summ.glm)
}

if (getRversion() >= "3.6.0") {
S3method(knitr::knit_print, summ.lm)
} else {
export(knit_print.summ.lm)
}

if (getRversion() >= "3.6.0") {
S3method(knitr::knit_print, summ.merMod)
} else {
export(knit_print.summ.merMod)
}

if (getRversion() >= "3.6.0") {
S3method(knitr::knit_print, summ.rq)
} else {
export(knit_print.summ.rq)
}

if (getRversion() >= "3.6.0") {
S3method(knitr::knit_print, summ.svyglm)
} else {
export(knit_print.summ.svyglm)
}

if (getRversion() >= "3.6.0") {
S3method(generics::glance, summ.lm)
} else {
export(glance.summ.lm)
}

if (getRversion() >= "3.6.0") {
S3method(generics::glance, summ.glm)
} else {
export(glance.summ.glm)
}

if (getRversion() >= "3.6.0") {
S3method(generics::glance, summ.svyglm)
} else {
export(glance.summ.svyglm)
}

if (getRversion() >= "3.6.0") {
S3method(generics::glance, summ.merMod)
} else {
export(glance.summ.merMod)
}

if (getRversion() >= "3.6.0") {
S3method(generics::glance, summ.rq)
} else {
export(glance.summ.rq)
}

if (getRversion() >= "3.6.0") {
S3method(generics::tidy, summ)
} else {
export(tidy.summ)
}

if (getRversion() >= "3.6.0") {
S3method(generics::tidy, summ.merMod)
} else {
export(tidy.summ.merMod)
}
S3method("%just%",data.frame)
S3method("%just%",default)
S3method("%just%",list)
Expand All @@ -126,8 +42,15 @@ S3method(get_formula,brmsfit)
S3method(get_formula,default)
S3method(get_formula,panelmodel)
S3method(glance,summ.glm)
S3method(glance,summ.lm)
S3method(glance,summ.merMod)
S3method(glance,summ.rq)
S3method(glance,summ.svyglm)
S3method(knitr::knit_print,summ.glm)
S3method(knitr::knit_print,summ.lm)
S3method(knitr::knit_print,summ.merMod)
S3method(knitr::knit_print,summ.rq)
S3method(knitr::knit_print,summ.svyglm)
S3method(make_predictions,brmsfit)
S3method(make_predictions,default)
S3method(make_predictions,merMod)
Expand Down Expand Up @@ -159,6 +82,9 @@ S3method(summ,lm)
S3method(summ,merMod)
S3method(summ,rq)
S3method(summ,svyglm)
S3method(tidy,summ)
S3method(tidy,summ.merMod)
S3method(tidy,summary.glht)
export("%just%")
export("%just%<-")
export("%nin%")
Expand Down Expand Up @@ -212,13 +138,11 @@ export(weights_tests)
export(wgttest)
export(wrap_str)
export(wtd.sd)
import(broom)
import(broom.mixed)
import(cli)
import(ggplot2)
import(rlang)
importFrom(crayon,cyan)
importFrom(crayon,inverse)
importFrom(crayon,italic)
importFrom(crayon,red)
importFrom(crayon,underline)
importFrom(generics,glance)
importFrom(generics,tidy)
importFrom(ggplot2,aes_string)
Expand All @@ -234,6 +158,8 @@ importFrom(grDevices,rgb)
importFrom(magrittr,"%<>%")
importFrom(magrittr,"%>%")
importFrom(pander,pandoc.table.return)
importFrom(rlang,check_installed)
importFrom(rlang,is_installed)
importFrom(stats,"contrasts<-")
importFrom(stats,AIC)
importFrom(stats,BIC)
Expand Down
40 changes: 38 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,52 @@
# jtools 2.2.3.9999

Bug fix:
Bug fixes:
* `predict_merMod()` was miscalculating predictions under a specific set of
conditions: When the model was fit with `lme4::glmer()`, the link was not
identity, standard errors were simultaneously being calculated, and the
user included random effects. This error has been corrected
([#144](https://github.com/jacob-long/jtools/issues/144))
* When printing `summ.glm()` results with `knitr`, the *p* value for the
omnibus chi-squared test is now included in the model statistics, like it
already is when using the function in the console. ([#138](https://github.com/jacob-long/jtools/issues/138)
* `effect_plot()` no longer fails with an error when models weights are
specified without a variable name.
([#156](https://github.com/jacob-long/jtools/issues/156))

Enhancement:
Enhancements:

* `summ()` will now produce model fit statistics for `glm.nb` models
([#142](https://github.com/jacob-long/jtools/issues/142)).
* `effect_plot()` now includes the argument `facet.by`. If you want to plot
your prediction variable at multiple values of some other variable, you can
pass the name of that variable to `facet.by`. It will, by default, create a
separate plot for each unique level of that variable using
`ggplot2::facet_wrap()`. If you only want specific levels of the `facet.by`
variable, you can specify them by giving a vector of values to the `at` argument.
More than most kinds of plots, you may need to do some further customization
to the results of `effect_plot()` since the plots may not fit the space well,
or you may want to rearrange into different row/column configurations, etc. I
expect this to be most useful for cases when you have a multilevel model and
there is a random slope specified for the `pred` variable. A version of this
feature was requested by Github user *5tokesy* (#147).
* `plot_coefs()` now handles `fixest_multi` objects from the `fixest` package
out of the box. (#123)
* The `omit.coefs` and `coefs` arguments to `plot_coefs()` can now be modified
using the new argument, `coefs.match`. You may use regular expressions to more
efficiently match coefficient names, which will be most useful when you have
models with many coefficients with predictable naming schemes. To have your
arguments interepreted this way, set `coefs.match = "regex"`.
([#122](https://github.com/jacob-long/jtools/issues/122))

Other changes:

* Removed `tidy.glht()` method because the `broom` package now implements one.
(#139)
* Made `broom` and `broom.mixed` hard dependencies to help avoid user confusion
and a few errors that could occur when one was missing. (#149)
* `cli` is now used to format (colorizing, italicizing, etc.) console output
rather than `crayon`. Please report any issues if formatting doesn't work
right for you; there shouldn't be any changes from past releases.

# jtools 2.2.2

Expand Down
Loading

0 comments on commit be1e0bd

Please sign in to comment.