From 4aa0c445db99e15c4bbc7ff92b808d239e10237e Mon Sep 17 00:00:00 2001 From: Grant McDermott Date: Sat, 28 Nov 2026 15:47:26 -0800 Subject: [PATCH] docs(errorbar): fix tick-label dictionary example The labeller dictionary swapped manual and automatic (am = 0 is automatic) and misspelled 'Cylinders'. --- R/type_errorbar.R | 12 ++++++------ man/type_errorbar.Rd | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/R/type_errorbar.R b/R/type_errorbar.R index fff2dddc..7e16e523 100644 --- a/R/type_errorbar.R +++ b/R/type_errorbar.R @@ -141,12 +141,12 @@ #' demo_plot(theme = "clean", xaxr = 45) #' # 2) dynamic theme + labeller function (here: dictionary w/ newline spacing) #' dict = c( -#' "factor(cyl)4" = "Manual\n4 Cyclinders", -#' "factor(cyl)6" = "Manual\n6 Cyclinders", -#' "factor(cyl)8" = "Manual\n8 Cyclinders", -#' "factor(am)1" = "Automatic\n4 Cylinders", -#' "factor(cyl)6:factor(am)1" = "Automatic\n6 Cylinders", -#' "factor(cyl)8:factor(am)1" = "Automatic\n8 Cylinders" +#' "factor(cyl)4" = "Automatic\n4 Cylinders", +#' "factor(cyl)6" = "Automatic\n6 Cylinders", +#' "factor(cyl)8" = "Automatic\n8 Cylinders", +#' "factor(am)1" = "Manual\n4 Cylinders", +#' "factor(cyl)6:factor(am)1" = "Manual\n6 Cylinders", +#' "factor(cyl)8:factor(am)1" = "Manual\n8 Cylinders" #' ) #' demo_plot(theme = "clean", xaxl = dict) #' # 3) dynamic theme + flipped axes diff --git a/man/type_errorbar.Rd b/man/type_errorbar.Rd index 3a329a8c..42971117 100644 --- a/man/type_errorbar.Rd +++ b/man/type_errorbar.Rd @@ -182,12 +182,12 @@ demo_plot() demo_plot(theme = "clean", xaxr = 45) # 2) dynamic theme + labeller function (here: dictionary w/ newline spacing) dict = c( - "factor(cyl)4" = "Manual\n4 Cyclinders", - "factor(cyl)6" = "Manual\n6 Cyclinders", - "factor(cyl)8" = "Manual\n8 Cyclinders", - "factor(am)1" = "Automatic\n4 Cylinders", - "factor(cyl)6:factor(am)1" = "Automatic\n6 Cylinders", - "factor(cyl)8:factor(am)1" = "Automatic\n8 Cylinders" + "factor(cyl)4" = "Automatic\n4 Cylinders", + "factor(cyl)6" = "Automatic\n6 Cylinders", + "factor(cyl)8" = "Automatic\n8 Cylinders", + "factor(am)1" = "Manual\n4 Cylinders", + "factor(cyl)6:factor(am)1" = "Manual\n6 Cylinders", + "factor(cyl)8:factor(am)1" = "Manual\n8 Cylinders" ) demo_plot(theme = "clean", xaxl = dict) # 3) dynamic theme + flipped axes