Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: report
Type: Package
Title: Automated Reporting of Results and Statistical Models
Version: 0.6.1.2
Version: 0.6.1.3
Authors@R:
c(person(given = "Dominique",
family = "Makowski",
Expand Down
1 change: 1 addition & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

Bug fixes

* `report.anova()`: fix missing denominator degrees of freedom in lmerTest ANOVA reports (#453)
* Fixed issue with missing effect size for the Intercept term in type 3 anova tables (#451)

# report 0.6.1
Expand Down
2 changes: 2 additions & 0 deletions R/report.aov.R
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,8 @@ report_statistics.aov <- function(x, table = NULL, ...) {
text <- paste0(text, ", ", insight::format_value(DoF_residual, protect_integers = TRUE))
} else if ("DoF_Residuals" %in% names(parameters)) {
text <- paste0(text, ", ", insight::format_value(parameters$DoF_Residuals, protect_integers = TRUE))
} else if ("df_error" %in% names(parameters)) {
text <- paste0(text, ", ", insight::format_value(parameters$df_error, protect_integers = TRUE))
}

# Indices
Expand Down
16 changes: 16 additions & 0 deletions tests/testthat/test-report.lmer.R
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,19 @@ test_that("report-lmer", {

expect_snapshot(variant = "windows", report(m2))
})

test_that("report-lmerTest-anova includes denominator df", {
skip_if_not_installed("lmerTest")

# Test case for issue #453: lmerTest ANOVA should include denominator degrees of freedom
m <- lmerTest::lmer(mpg ~ wt + (1 | gear), data = mtcars)
anova_result <- anova(m)
report_output <- report(anova_result)

# The report should include denominator df in F-statistic
# Should be F(1, 21.92) not just F(1)
expect_match(as.character(report_output), "F\\(1, [0-9.]+\\)")

# Should not have the old pattern without denominator df
expect_no_match(as.character(report_output), "F\\(1\\) =")
})