Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pull Request by Zilin Huang regarding Issue #221 #228

Open
wants to merge 17 commits into
base: main
Choose a base branch
from
2 changes: 1 addition & 1 deletion R/ggcuminc.R
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ ggcuminc <- function(x, outcome = NULL,
cli_inform("Plotting outcome {.val {outcome}}.")
}
if (any(!outcome %in% unique(df$outcome))) {
cli_abort("Argument {.code outcome} must be one or more of {.val {unique(df$outcome)}}")
cli_abort("Argument {.arg x} does not support {.cls survfit.coxphms} object.")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand this change to the error message. Was this intentional?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ddsjoberg apologize that I may make this change by mistake. I have changed this section back to its original version (with "Argument {.code outcome}")

}
df <- dplyr::filter(df, .data$outcome %in% .env$outcome)

Expand Down
1 change: 1 addition & 0 deletions R/scale_ggsurvfit.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
#' # specify additional scales
#' ggsurvfit +
#' scale_ggsurvfit(x_scales = list(breaks = seq(0, 8, by = 2)))

#' @inherit ggsurvfit seealso
scale_ggsurvfit <- function(x_scales = list(), y_scales = list()){
scale_ggsurvfit_empty_list <- list()
Expand Down
3 changes: 2 additions & 1 deletion R/utils-add_risktable.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
}

# get data to place in risktables --------------------------------------------
times <- times %||% plot_build$layout$panel_params[[1]]$x.sec$breaks
times <- times %||% plot_build$layout$panel_params[[1]]$x$breaks

df_times <-
.prepare_data_for_risk_tables(data = x$data, times = times, combine_groups = combine_groups)

Expand Down
9 changes: 9 additions & 0 deletions man/scale_ggsurvfit.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

47 changes: 8 additions & 39 deletions man/stepribbon.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading