Skip to content

Commit

Permalink
better titles
Browse files Browse the repository at this point in the history
  • Loading branch information
strengejacke committed Mar 20, 2024
1 parent e1e8aa3 commit b801dfc
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions R/plot.performance_simres.R
Original file line number Diff line number Diff line change
Expand Up @@ -123,12 +123,23 @@ plot.see_performance_simres <- function(x,
y_lab <- "Sample Quantiles"
}

if (is.null(transform)) {
p_title <- "Uniformity of Residuals"
p_x <- "Standard Uniform Distribution Quantiles"
} else if (identical(transform, stats::qnorm)) {
p_title <- "Normality of Residuals"
p_x <- "Standard Normal Distribution Quantiles"
} else {
p_title <- "Residuals Check"
p_x <- "Distribution of Quantiles"
}

gg_init +
qq_stuff +
ggplot2::labs(
title = ifelse(is.null(transform), "Uniformity of Residuals", "Residuals Check"),
title = p_title,
subtitle = "Dots should fall along the line",
x = ifelse(is.null(transform), "Standard Uniform Distribution Quantiles", "Distribution of Quantiles"),
x = p_x,
y = y_lab
) +
style(
Expand Down

0 comments on commit b801dfc

Please sign in to comment.