* using log directory 'd:/Rcompile/CRANpkg/local/4.7/gtregression.Rcheck' * using R Under development (unstable) (2026-05-01 r89993 ucrt) * using platform: x86_64-w64-mingw32 * R was compiled by gcc.exe (GCC) 14.3.0 GNU Fortran (GCC) 14.3.0 * running under: Windows Server 2022 x64 (build 20348) * using session charset: UTF-8 * current time: 2026-05-03 13:33:16 UTC * checking for file 'gtregression/DESCRIPTION' ... OK * checking extension type ... Package * this is package 'gtregression' version '1.0.0' * package encoding: UTF-8 * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking whether package 'gtregression' can be installed ... OK * checking installed package size ... OK * checking package directory ... OK * checking 'build' directory ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking code files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... [3s] OK * checking whether the package can be loaded with stated dependencies ... [2s] OK * checking whether the package can be unloaded cleanly ... [2s] OK * checking whether the namespace can be loaded with stated dependencies ... [3s] OK * checking whether the namespace can be unloaded cleanly ... [3s] OK * checking loading without being on the library search path ... [3s] OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... [8s] OK * checking Rd files ... [1s] OK * checking Rd metadata ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking contents of 'data' directory ... OK * checking data for non-ASCII characters ... [0s] OK * checking LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking installed files from 'inst/doc' ... OK * checking files in 'vignettes' ... OK * checking examples ... [19s] OK * checking for unstated dependencies in 'tests' ... OK * checking tests ... [200s] ERROR Running 'testthat.R' [200s] Running the tests in 'tests/testthat.R' failed. Complete output: > # This file is part of the standard setup for testthat. > # It is recommended that you do not modify it. > # > # Where should you do additional test configuration? > # Learn more about the roles of various files in: > # * https://r-pkgs.org/testing-design.html#sec-tests-files-overview > # * https://testthat.r-lib.org/articles/special-files.html > > library(testthat) > library(gtregression) > > test_check("gtregression") Attaching package: 'dplyr' The following objects are masked from 'package:stats': filter, lag The following objects are masked from 'package:base': intersect, setdiff, setequal, union Saving _problems/test-descriptive_table-122.R Saving _problems/test-descriptive_table-123.R # A tibble: 18 x 6 Variable Type `Missing (%)` Unique Levels Compatibility 1 pregnant numeric 0% 17 - compatible 2 glucose numeric 0.7% 135 - compatible 3 pressure numeric 4.6% 46 - compatible 4 triceps numeric 29.6% 50 - compatible 5 insulin numeric 48.7% 185 - compatible 6 mass numeric 1.4% 247 - compatible 7 pedigree numeric 0% 517 - compatible 8 age numeric 0% 52 - compatible 9 diabetes numeric 0% 2 - maybe 10 bmi factor 1.4% 3 Normal, Overweight, ~ compatible 11 age_cat factor 0% 3 Young, Middle-aged, ~ compatible 12 npreg_cat factor 0% 2 Low parity, High par~ compatible 13 glucose_cat factor 0.7% 2 Normal, High compatible 14 bp_cat factor 4.6% 2 Normal, High compatible 15 triceps_cat factor 29.6% 2 Normal, High compatible 16 insulin_cat factor 48.7% 3 Low, Normal, High compatible 17 dpf_cat factor 0% 3 Low Genetic Risk, Mo~ compatible 18 diabetes_cat factor 0% 2 Diabetes negative, D~ compatible Interpretation notes: - compatible: ready to use in regression - maybe: require transformation to factor or check no of levels - incompatible: not usable as-is (e.g., all NA, <2 levels) ------------------------------------------------------------ Crude Estimate: 2.961 Adjusted Estimate: 2.496 % Change from Crude: 15.69% ------------------------------------------------------------ Confounding: Yes ------------------------------------------------------------ Notes: * Confounding is suggested if percent change >=10%. * This method does not assess effect modification. * Use DAGs or domain knowledge to support confounder identification. # A tibble: 4 x 5 covariate crude_est adjusted_est pct_change is_confounder 1 bmi 2.96 2.50 15.7 TRUE 2 age_cat 2.96 2.62 11.5 TRUE 3 npreg_cat 2.96 2.78 6.07 FALSE 4 bp_cat 2.96 NA NA NA Notes: * Confounding is suggested if percent change >=10%. * This method does not assess effect modification. * Use DAGs or domain knowledge to support confounder identification. ------------------------------------------------------------ Crude Estimate: 2.961 Adjusted Estimate: NA % Change from Crude: NA% ------------------------------------------------------------ Confounding: NA ------------------------------------------------------------ Notes: * Confounding is suggested if percent change >=10%. * This method does not assess effect modification. * Use DAGs or domain knowledge to support confounder identification. # A tibble: 4 x 5 covariate crude_est adjusted_est pct_change is_confounder 1 bmi 2.96 NA NA NA 2 age_cat 2.96 NA NA NA 3 npreg_cat 2.96 NA NA NA 4 bp_cat 2.96 NA NA NA Notes: * Confounding is suggested if percent change >=10%. * This method does not assess effect modification. * Use DAGs or domain knowledge to support confounder identification. # A tibble: 3 x 5 covariate crude_est adjusted_est pct_change is_confounder 1 Eth 1.18 1.24 4.98 FALSE 2 Age 1.18 1.01 14.5 TRUE 3 Lrn 1.18 1.21 2.37 FALSE Notes: * Confounding is suggested if percent change >=10%. * This method does not assess effect modification. * Use DAGs or domain knowledge to support confounder identification. --------------------------------------------------- Interaction Term Assessment usingLikelihood Ratio Test Model without interaction: diabetes ~ age_cat + glucose_cat Model with interaction: diabetes ~ age_cat + glucose_cat + age_cat:glucose_cat ----------------------------------------------------- P-value:0.1741 Interaction is not statistically significant. Simpler model may be preferred. ---------------------------------------------------- --------------------------------------------------- Interaction Term Assessment usingLikelihood Ratio Test Model without interaction: diabetes ~ age_cat + glucose_cat Model with interaction: diabetes ~ age_cat + glucose_cat + age_cat:glucose_cat ----------------------------------------------------- P-value:0.0100 Interaction is statistically significant. Consider including it. ---------------------------------------------------- The number rows in the tables to be merged do not match, which may result in rows appearing out of order. i See `tbl_merge()` (`?gtsummary::tbl_merge()`) help file for details. Use `quiet=TRUE` to silence message. The number rows in the tables to be merged do not match, which may result in rows appearing out of order. i See `tbl_merge()` (`?gtsummary::tbl_merge()`) help file for details. Use `quiet=TRUE` to silence message. robpoisson: Implausible predicted probability >0.99999 occurred: 1.20967417078353 robpoisson: Implausible predicted probability >0.99999 occurred: 1.27352337518946 Table saved at: D:\temp\2026_05_03_01_50_00_26843\RtmpQVspmY\regression_results.docx `height` was translated to `width`. Plot saved at: D:\temp\2026_05_03_01_50_00_26843\RtmpQVspmY\plot_png.png `height` was translated to `width`. Plot saved at: D:\temp\2026_05_03_01_50_00_26843\RtmpQVspmY\plot_pdf.pdf `height` was translated to `width`. Plot saved at: D:\temp\2026_05_03_01_50_00_26843\RtmpQVspmY\plot_jpg.jpg `height` was translated to `width`. Word document saved at: D:\temp\2026_05_03_01_50_00_26843\RtmpQVspmY\final_report.docx If tables or plots extend beyond the page, consider switching to landscape layout in Word (Layout > Orientation > Landscape). Attaching package: 'MASS' The following object is masked from 'package:gtsummary': select The following object is masked from 'package:dplyr': select Running stratified multivariable regression by: glucose_cat > Stratum: glucose_cat = High > Stratum: glucose_cat = Normal Running stratified multivariable regression by: glucose_cat > Stratum: glucose_cat = Normal > Stratum: glucose_cat = High Running stratified multivariable regression by: glucose_cat > Stratum: glucose_cat = High > Stratum: glucose_cat = Normal Running stratified multivariable regression by: glucose_cat > Stratum: glucose_cat = High x There was an error calling `tidy_fun()`. Most likely, this is because the function supplied in `tidy_fun=` was misspelled, does not exist, is not compatible with your object, or was missing necessary arguments (e.g. `conf.level=` or `conf.int=`). See error message below. > Stratum: glucose_cat = Normal Running stratified univariate regression by: glucose_cat > Stratum: glucose_cat = High > Stratum: glucose_cat = Normal Running stratified univariate regression by: glucose_cat > Stratum: glucose_cat = Normal > Stratum: glucose_cat = High Running stratified univariate regression by: glucose_cat > Stratum: glucose_cat = High > Stratum: glucose_cat = Normal Running stratified univariate regression by: age_cat > Stratum: age_cat = Older > Stratum: age_cat = Middle-aged > Stratum: age_cat = Young Running stratified univariate regression by: glucose_cat Call: glm(formula = formula, family = binomial("logit"), data = data) Coefficients: (Intercept) glucose -6.09552 0.04242 Degrees of Freedom: 391 Total (i.e. Null); 390 Residual Null Deviance: 498.1 Residual Deviance: 386.7 AIC: 390.7 [ FAIL 2 | WARN 21 | SKIP 2 | PASS 240 ] ══ Skipped tests (2) ═══════════════════════════════════════════════════════════ • On CRAN (2): 'test-dissect.R:1:1', 'test-multi_reg.R:62:7' ══ Failed tests ════════════════════════════════════════════════════════════════ ── Failure ('test-descriptive_table.R:113:3'): descriptive_table works with row percentages ── Expected `... <- NULL` not to throw any errors. Actually got a with message: row names contain missing values Backtrace: ▆ 1. ├─testthat::expect_error(...) at test-descriptive_table.R:113:3 2. │ └─testthat:::expect_condition_matching_(...) 3. │ └─testthat:::quasi_capture(...) 4. │ ├─testthat (local) .capture(...) 5. │ │ └─base::withCallingHandlers(...) 6. │ └─rlang::eval_bare(quo_get_expr(.quo), quo_get_env(.quo)) 7. ├─gtregression::descriptive_table(...) 8. │ ├─gtsummary::add_overall(...) 9. │ └─gtsummary:::add_overall.tbl_summary(...) 10. │ └─gtsummary:::add_overall_generic(...) 11. │ ├─base::do.call(calling_fun, args_overall) 12. │ └─gtsummary::tbl_summary(...) 13. │ ├─cards::replace_null_statistic(...) 14. │ │ └─cards:::check_class(x, "card") 15. │ ├─... %>% structure(., class = c("card", class(.))) 16. │ ├─cards::bind_ard(...) 17. │ │ └─dplyr::bind_rows(...) 18. │ │ └─rlang::list2(...) 19. │ ├─cards::ard_tabulate(...) 20. │ └─cards:::ard_tabulate.data.frame(...) 21. │ └─cards:::.calculate_tabulation_statistics(...) 22. │ └─cards:::.process_denominator(...) 23. │ ├─stats::setNames(...) 24. │ └─base::lapply(...) 25. │ └─cards (local) FUN(X[[i]], ...) 26. │ ├─dplyr::summarise(...) 27. │ ├─tidyr::drop_na(...) 28. │ └─cards:::.table_as_df(...) 29. │ ├─dplyr::as_tibble(...) 30. │ └─tibble:::as_tibble.table(...) 31. │ ├─base::as.data.frame(x, stringsAsFactors = FALSE) 32. │ └─base::as.data.frame.table(x, stringsAsFactors = FALSE) 33. │ ├─base::eval(ex) 34. │ │ └─base::eval(ex) 35. │ └─base::data.frame(...) 36. │ ├─base::as.data.frame(x[[i]], optional = TRUE) 37. │ └─base::as.data.frame.integer(x[[i]], optional = TRUE) 38. └─base::structure(., class = c("card", class(.))) ── Failure ('test-descriptive_table.R:123:3'): descriptive_table works with row percentages ── Expected `tbl` to be an S3 object. Actual OO type: none. [ FAIL 2 | WARN 21 | SKIP 2 | PASS 240 ] Error: ! Test failures. Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes ... OK * checking re-building of vignette outputs ... [2s] OK * checking PDF version of manual ... [20s] OK * checking HTML version of manual ... [7s] OK * DONE Status: 1 ERROR