diff --git a/NAMESPACE b/NAMESPACE index 8e8a7a23..cbc6d0ec 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -100,7 +100,6 @@ export(regression_model_list) export(regression_model_uv) export(regression_model_uv_list) export(regression_table) -export(regression_table_create) export(remove_empty_attr) export(remove_empty_cols) export(remove_nested_list) diff --git a/NEWS.md b/NEWS.md index 2cd0e65b..5f097c19 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,7 +1,3 @@ -# FreesearchR 25.5.5 - -- *FIX* several minor bugs and polish - # FreesearchR 25.5.4 - *FIX* correctly omit NAs in `data_type()` call diff --git a/R/data-import.R b/R/data-import.R index cbaa0478..8ef1dacd 100644 --- a/R/data-import.R +++ b/R/data-import.R @@ -35,7 +35,7 @@ data_import_ui <- function(id) { ), shiny::conditionalPanel( condition = "input.source=='env'", - datamods::import_globalenv_ui(id = ns("env"), title = NULL) + import_globalenv_ui(id = ns("env"), title = NULL) ), shiny::conditionalPanel( condition = "input.source=='redcap'", diff --git a/R/hosted_version.R b/R/hosted_version.R index 32d9fe0f..596d4e21 100644 --- a/R/hosted_version.R +++ b/R/hosted_version.R @@ -1 +1 @@ -hosted_version <- function()'v25.5.4-250512' +hosted_version <- function()'v25.5.4-250510' diff --git a/R/regression_table.R b/R/regression_table.R index 71e99272..3dea4a50 100644 --- a/R/regression_table.R +++ b/R/regression_table.R @@ -96,31 +96,18 @@ #' # gtsummary::bold_p() #' } regression_table <- function(x, ...) { - args <- list(...) - if ("list" %in% class(x)) { x |> purrr::map(\(.m){ - regression_table_create(x = .m, args.list = args) |> + regression_table_create(x = .m, ...) |> gtsummary::add_n() }) |> gtsummary::tbl_stack() } else { - regression_table_create(x, args.list = args) + regression_table_create(x, ...) } } -#' Create regression summary table -#' -#' @param x (list of) regression model -#' @param ... ignored for now -#' @param args.list args.list for the summary function -#' @param fun table summary function. Default is "gtsummary::tbl_regression" -#' @param theme summary table theme -#' -#' @returns gtsummary list object -#' @export -#' regression_table_create <- function(x, ..., args.list = NULL, fun = "gtsummary::tbl_regression", theme = c("jama", "lancet", "nejm", "qjecon")) { # Stripping custom class class(x) <- class(x)[class(x) != "freesearchr_model"] diff --git a/inst/apps/FreesearchR/app.R b/inst/apps/FreesearchR/app.R index 7882c2ca..7dff7246 100644 --- a/inst/apps/FreesearchR/app.R +++ b/inst/apps/FreesearchR/app.R @@ -26,7 +26,7 @@ library(shiny) # library(DHARMa) # library(apexcharter) library(toastui) -library(datamods) +# library(datamods) # library(IDEAFilter) library(shinyWidgets) # library(DT) @@ -49,7 +49,7 @@ library(rlang) #### Current file: /Users/au301842/FreesearchR/R//app_version.R ######## -app_version <- function()'25.5.4' +app_version <- function()'25.5.3' ######## @@ -2455,7 +2455,7 @@ data_import_ui <- function(id) { ), shiny::conditionalPanel( condition = "input.source=='env'", - datamods::import_globalenv_ui(id = ns("env"), title = NULL) + import_globalenv_ui(id = ns("env"), title = NULL) ), shiny::conditionalPanel( condition = "input.source=='redcap'", @@ -3996,7 +3996,7 @@ simple_snake <- function(data){ #### Current file: /Users/au301842/FreesearchR/R//hosted_version.R ######## -hosted_version <- function()'v25.5.4-250512' +hosted_version <- function()'v25.5.3-250510' ######## @@ -7090,31 +7090,18 @@ symmetrical_scale_x_log10 <- function(plot, breaks = c(1, 2, 3, 5, 10), ...) { #' # gtsummary::bold_p() #' } regression_table <- function(x, ...) { - args <- list(...) - if ("list" %in% class(x)) { x |> purrr::map(\(.m){ - regression_table_create(x = .m, args.list = args) |> + regression_table_create(x = .m, ...) |> gtsummary::add_n() }) |> gtsummary::tbl_stack() } else { - regression_table_create(x, args.list = args) + regression_table_create(x, ...) } } -#' Create regression summary table -#' -#' @param x (list of) regression model -#' @param ... ignored for now -#' @param args.list args.list for the summary function -#' @param fun table summary function. Default is "gtsummary::tbl_regression" -#' @param theme summary table theme -#' -#' @returns gtsummary list object -#' @export -#' regression_table_create <- function(x, ..., args.list = NULL, fun = "gtsummary::tbl_regression", theme = c("jama", "lancet", "nejm", "qjecon")) { # Stripping custom class class(x) <- class(x)[class(x) != "freesearchr_model"] diff --git a/man/regression_table_create.Rd b/man/regression_table_create.Rd deleted file mode 100644 index dcf5ef20..00000000 --- a/man/regression_table_create.Rd +++ /dev/null @@ -1,31 +0,0 @@ -% Generated by roxygen2: do not edit by hand -% Please edit documentation in R/regression_table.R -\name{regression_table_create} -\alias{regression_table_create} -\title{Create regression summary table} -\usage{ -regression_table_create( - x, - ..., - args.list = NULL, - fun = "gtsummary::tbl_regression", - theme = c("jama", "lancet", "nejm", "qjecon") -) -} -\arguments{ -\item{x}{(list of) regression model} - -\item{...}{ignored for now} - -\item{args.list}{args.list for the summary function} - -\item{fun}{table summary function. Default is "gtsummary::tbl_regression"} - -\item{theme}{summary table theme} -} -\value{ -gtsummary list object -} -\description{ -Create regression summary table -}