From 1dd6c0fc9f108ce8bdc0964f3aff08888346bdd7 Mon Sep 17 00:00:00 2001 From: vedhav Date: Fri, 24 Nov 2023 16:57:31 +0530 Subject: [PATCH] fix: ci fixes - lints and docs --- .lintr | 8 ++++---- R/tm_g_gh_correlationplot.R | 2 +- R/utils-data_constraints.r | 2 +- R/utils.R | 2 +- man/report_card_template_goshawk.Rd | 9 +++++++++ 5 files changed, 16 insertions(+), 7 deletions(-) diff --git a/.lintr b/.lintr index f6baca2b..e8937577 100644 --- a/.lintr +++ b/.lintr @@ -1,5 +1,5 @@ linters: linters_with_defaults( - line_length_linter = line_length_linter(120), - cyclocomp_linter = NULL, - object_usage_linter = NULL -) + line_length_linter = line_length_linter(120), + cyclocomp_linter = NULL, + object_usage_linter = NULL + ) diff --git a/R/tm_g_gh_correlationplot.R b/R/tm_g_gh_correlationplot.R index 78d13ddd..3c55a3d8 100644 --- a/R/tm_g_gh_correlationplot.R +++ b/R/tm_g_gh_correlationplot.R @@ -526,7 +526,7 @@ srv_g_correlationplot <- function(id, # get min max values if ((constraint_var == "BASE2" && any(grepl("SCR", visit_freq))) || - (constraint_var == "BASE" && any(grepl("BL", visit_freq)))) { + (constraint_var == "BASE" && any(grepl("BL", visit_freq)))) { # nolint val <- stats::na.omit(switch(constraint_var, "BASE" = ANL$BASE[ANL$AVISITCD == "BL"], "BASE2" = ANL$BASE2[ANL$AVISITCD == "SCR"], diff --git a/R/utils-data_constraints.r b/R/utils-data_constraints.r index a276c5dc..f8efe57a 100644 --- a/R/utils-data_constraints.r +++ b/R/utils-data_constraints.r @@ -107,7 +107,7 @@ constr_anl_q <- function(session, input, data, dataname, param_id, param_var, tr # get min max values if ((constraint_var == "BASE2" && any(grepl("SCR", visit_freq))) || - (constraint_var == "BASE" && any(grepl("BL", visit_freq)))) { + (constraint_var == "BASE" && any(grepl("BL", visit_freq)))) { # nolint val <- stats::na.omit(switch(constraint_var, "BASE" = ANL$BASE[ANL$AVISITCD == "BL"], "BASE2" = ANL$BASE2[ANL$AVISITCD == "SCR"], diff --git a/R/utils.R b/R/utils.R index 6a881b39..89490753 100644 --- a/R/utils.R +++ b/R/utils.R @@ -38,7 +38,7 @@ plots_per_row_validate_rules <- function(required = TRUE) { #' an optional description, and the option to append the filter state list. #' Additionally, it display selected constraint options. #' -#' @inheritParams teal.reporter::card_template +#' @inheritParams teal::report_card_template #' @param constraint_list (`list`) a list containing constraint variables, including: #' - constraint_var (`character(1)`) the constraint variable name. #' - constraint_range_min (`numeric(1)`) the minimum constraint range value. diff --git a/man/report_card_template_goshawk.Rd b/man/report_card_template_goshawk.Rd index c5101303..7172a59e 100644 --- a/man/report_card_template_goshawk.Rd +++ b/man/report_card_template_goshawk.Rd @@ -15,6 +15,15 @@ report_card_template_goshawk( ) } \arguments{ +\item{title}{(\code{character(1)}) title of the card (unless overwritten by label)} + +\item{label}{(\code{character(1)}) label provided by the user when adding the card} + +\item{with_filter}{(\code{logical(1)}) flag indicating to add filter state} + +\item{filter_panel_api}{(\code{FilterPanelAPI}) object with API that allows the generation +of the filter state in the report} + \item{constraint_list}{(\code{list}) a list containing constraint variables, including: \itemize{ \item constraint_var (\code{character(1)}) the constraint variable name.