From 4917d25086c4355d40ed455e6be21fe8d32cc8b3 Mon Sep 17 00:00:00 2001 From: "Zhao, Yujie" Date: Wed, 3 Jan 2024 09:56:45 -0500 Subject: [PATCH] lint r issue of the space --- R/gs_design_ahr.R | 2 +- R/gs_design_combo.R | 2 +- R/gs_design_wlr.R | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/R/gs_design_ahr.R b/R/gs_design_ahr.R index 0ed9603e..307c5d65 100644 --- a/R/gs_design_ahr.R +++ b/R/gs_design_ahr.R @@ -236,7 +236,7 @@ gs_design_ahr <- function( if ((length(analysis_time) > 1) && (length(info_frac) > 1) && (length(info_frac) != length(analysis_time))) { stop("gs_design_ahr() info_frac and analysis_time must have the same length if both have length > 1.") } - if(all(fail_rate$hr == 1)) { + if (all(fail_rate$hr == 1)) { stop("gs_design_ahr() hr must not be equal to 1 throughout the study as this is the null hypothesis.") } diff --git a/R/gs_design_combo.R b/R/gs_design_combo.R index bf4ecf1d..7bf14223 100644 --- a/R/gs_design_combo.R +++ b/R/gs_design_combo.R @@ -178,7 +178,7 @@ gs_design_combo <- function( two_sided <- TRUE } - if(all(fail_rate$hr == 1)) { + if (all(fail_rate$hr == 1)) { stop("gs_design_combo() hr must not be equal to 1 throughout the study as this is the null hypothesis.") } diff --git a/R/gs_design_wlr.R b/R/gs_design_wlr.R index 4d588e13..16082908 100644 --- a/R/gs_design_wlr.R +++ b/R/gs_design_wlr.R @@ -152,7 +152,7 @@ gs_design_wlr <- function( if (max(info_frac) != 1) stop(msg) msg <- "gs_design_wlr(): info_frac and analysis_time must have the same length if both have length > 1" if ((length(analysis_time) > 1) && (length(info_frac) > 1) && (length(info_frac) != length(analysis_time))) stop(msg) - if(all(fail_rate$hr == 1)) { + if (all(fail_rate$hr == 1)) { stop("gs_design_wlr() hr must not be equal to 1 throughout the study as this is the null hypothesis.") } # get the info_scale