From 01b4f10fdcee1802e18c406fdbf4ed9b001c5ae7 Mon Sep 17 00:00:00 2001 From: "Trevor L. Davis" Date: Wed, 17 Apr 2024 21:22:22 -0700 Subject: [PATCH] fix: Use 'transform' argument * In {ggplot2} the `trans` argument was deprecated, uses `transform` instead closes #113 --- DESCRIPTION | 2 +- R/scale-pattern-size.R | 10 +- R/scale-pattern.R | 228 +++++++++--------- .../generate-scales-continuous-discrete.R | 24 +- man/scale_continuous.Rd | 26 +- man/scale_discrete.Rd | 18 +- man/scale_pattern_size_continuous.Rd | 6 +- 7 files changed, 157 insertions(+), 157 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 71a428d..9c3efc1 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: ggpattern Type: Package Title: 'ggplot2' Pattern Geoms -Version: 1.1.0-5 +Version: 1.1.0-6 Authors@R: c(person("Mike", "FC", role = "aut"), person("Trevor L.", "Davis", role = c("aut", "cre"), email = "trevor.l.davis@gmail.com", diff --git a/R/scale-pattern-size.R b/R/scale-pattern-size.R index fff660f..83f7020 100644 --- a/R/scale-pattern-size.R +++ b/R/scale-pattern-size.R @@ -1,7 +1,7 @@ #----------------------------------------------------------------------------- #' Scales for area or radius #' -#' @param name,breaks,labels,limits,trans,guide See \code{ggplot2::scale_size} for more information +#' @param name,breaks,labels,limits,transform,guide See \code{ggplot2::scale_size} for more information #' @param range a numeric vector of length 2 that specifies the minimum and #' maximum size of the plotting symbol after transformation. #' @return A [ggplot2::Scale] object. @@ -33,9 +33,9 @@ #----------------------------------------------------------------------------- scale_pattern_size_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, range = c(1, 6), - trans = "identity", guide = "legend") { + transform = "identity", guide = "legend") { continuous_scale("pattern_size", palette = area_pal(range), name = name, - breaks = breaks, labels = labels, limits = limits, trans = trans, + breaks = breaks, labels = labels, limits = limits, transform = transform, guide = guide) } @@ -52,9 +52,9 @@ scale_pattern_size <- scale_pattern_size_continuous # #----------------------------------------------------------------------------- # scale_size_binned <- function(name = waiver(), breaks = waiver(), labels = waiver(), # limits = NULL, range = c(1, 6), n.breaks = NULL, -# nice.breaks = TRUE, trans = "identity", guide = "bins") { +# nice.breaks = TRUE, transform = "identity", guide = "bins") { # binned_scale("size", palette = area_pal(range), name = name, -# breaks = breaks, labels = labels, limits = limits, trans = trans, +# breaks = breaks, labels = labels, limits = limits, transform = transform, # n.breaks = n.breaks, nice.breaks = nice.breaks, guide = guide) # } diff --git a/R/scale-pattern.R b/R/scale-pattern.R index 734abc9..81eb6ea 100644 --- a/R/scale-pattern.R +++ b/R/scale-pattern.R @@ -10,7 +10,7 @@ #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #' Scales for continuous pattern aesthetics #' -#' @param name,breaks,labels,limits,range,trans,guide,... See +#' @param name,breaks,labels,limits,range,transform,guide,... See #' \code{{ggplot2}} documentation for more information on scales. #' #' @return A [ggplot2::Scale] object. @@ -46,7 +46,7 @@ NULL #' Scales for discrete pattern aesthetics #' #' @param choices vector of values to choose from. -#' @param name,breaks,labels,limits,trans,guide,... See +#' @param name,breaks,labels,limits,transform,guide,... See #' \code{{ggplot2}} documentation for more information on scales. #' #' @return A [ggplot2::Scale] object. @@ -80,7 +80,7 @@ NULL #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = c('stripe', 'crosshatch', 'circle'), - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -94,7 +94,7 @@ scale_pattern_continuous <- function(name = waiver(), breaks = waiver(), labels breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -127,7 +127,7 @@ scale_pattern_discrete <- function(..., choices = c('stripe', 'crosshatch', 'cir #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_type_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = NULL, - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -141,7 +141,7 @@ scale_pattern_type_continuous <- function(name = waiver(), breaks = waiver(), la breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -174,7 +174,7 @@ scale_pattern_type_discrete <- function(..., choices = NULL, guide = 'legend') { #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_subtype_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = NULL, - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -188,7 +188,7 @@ scale_pattern_subtype_continuous <- function(name = waiver(), breaks = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -219,13 +219,13 @@ scale_pattern_subtype_discrete <- function(..., choices = NULL, guide = 'legend' #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_angle_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0, 90), - trans = 'identity', - guide = 'legend') { +scale_pattern_angle_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0, 90), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -239,7 +239,7 @@ scale_pattern_angle_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -265,13 +265,13 @@ scale_pattern_angle_discrete <- function(..., range = c(0, 90)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_density_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0, 0.5), - trans = 'identity', - guide = 'legend') { +scale_pattern_density_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0, 0.5), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -285,7 +285,7 @@ scale_pattern_density_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -311,13 +311,13 @@ scale_pattern_density_discrete <- function(..., range = c(0, 0.5)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_spacing_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.01, 0.1), - trans = 'identity', - guide = 'legend') { +scale_pattern_spacing_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.01, 0.1), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -331,7 +331,7 @@ scale_pattern_spacing_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -357,13 +357,13 @@ scale_pattern_spacing_discrete <- function(..., range = c(0.01, 0.1)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_xoffset_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.01, 0.1), - trans = 'identity', - guide = 'legend') { +scale_pattern_xoffset_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.01, 0.1), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -377,7 +377,7 @@ scale_pattern_xoffset_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -403,13 +403,13 @@ scale_pattern_xoffset_discrete <- function(..., range = c(0.01, 0.1)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_yoffset_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.01, 0.1), - trans = 'identity', - guide = 'legend') { +scale_pattern_yoffset_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.01, 0.1), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -423,7 +423,7 @@ scale_pattern_yoffset_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -449,13 +449,13 @@ scale_pattern_yoffset_discrete <- function(..., range = c(0.01, 0.1)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_aspect_ratio_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.5, 2), - trans = 'identity', - guide = 'legend') { +scale_pattern_aspect_ratio_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.5, 2), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -469,7 +469,7 @@ scale_pattern_aspect_ratio_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -495,13 +495,13 @@ scale_pattern_aspect_ratio_discrete <- function(..., range = c(0.5, 2)) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_key_scale_factor_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.5, 2), - trans = 'identity', - guide = 'legend') { +scale_pattern_key_scale_factor_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.5, 2), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -515,7 +515,7 @@ scale_pattern_key_scale_factor_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -543,7 +543,7 @@ scale_pattern_key_scale_factor_discrete <- function(..., range = c(0.5, 2)) { #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_filename_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = NULL, - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -557,7 +557,7 @@ scale_pattern_filename_continuous <- function(name = waiver(), breaks = waiver() breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -590,7 +590,7 @@ scale_pattern_filename_discrete <- function(..., choices = NULL, guide = 'legend #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_filter_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = c('lanczos', 'box', 'spline', 'cubic'), - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -604,7 +604,7 @@ scale_pattern_filter_continuous <- function(name = waiver(), breaks = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -637,7 +637,7 @@ scale_pattern_filter_discrete <- function(..., choices = c('lanczos', 'box', 'sp #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_gravity_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = c('center', 'north', 'south', 'east', 'west', 'northeast', 'northwest', 'southeast', 'southwest'), - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -651,7 +651,7 @@ scale_pattern_gravity_continuous <- function(name = waiver(), breaks = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -682,13 +682,13 @@ scale_pattern_gravity_discrete <- function(..., choices = c('center', 'north', ' #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_scale_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0.5, 2), - trans = 'identity', - guide = 'legend') { +scale_pattern_scale_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0.5, 2), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -702,7 +702,7 @@ scale_pattern_scale_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -730,7 +730,7 @@ scale_pattern_scale_discrete <- function(..., range = c(0.5, 2)) { #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_orientation_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = c('horizontal', 'vertical', 'radial'), - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -744,7 +744,7 @@ scale_pattern_orientation_continuous <- function(name = waiver(), breaks = waive breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -775,13 +775,13 @@ scale_pattern_orientation_discrete <- function(..., choices = c('horizontal', 'v #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_phase_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = NULL, - trans = 'identity', - guide = 'legend') { +scale_pattern_phase_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = NULL, + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -795,7 +795,7 @@ scale_pattern_phase_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -821,13 +821,13 @@ scale_pattern_phase_discrete <- function(..., range = NULL) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_frequency_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = NULL, - trans = 'identity', - guide = 'legend') { +scale_pattern_frequency_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = NULL, + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -841,7 +841,7 @@ scale_pattern_frequency_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -869,7 +869,7 @@ scale_pattern_frequency_discrete <- function(..., range = NULL) { #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_pattern_grid_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = c('square', 'hex'), - trans = 'identity', guide = 'legend') { + transform = 'identity', guide = 'legend') { if (is.null(choices)) { @@ -883,7 +883,7 @@ scale_pattern_grid_continuous <- function(name = waiver(), breaks = waiver(), la breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) } @@ -914,13 +914,13 @@ scale_pattern_grid_discrete <- function(..., choices = c('square', 'hex'), guide #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_res_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = NULL, - trans = 'identity', - guide = 'legend') { +scale_pattern_res_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = NULL, + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -934,7 +934,7 @@ scale_pattern_res_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } @@ -960,13 +960,13 @@ scale_pattern_res_discrete <- function(..., range = NULL) { #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_pattern_rot_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = c(0, 360), - trans = 'identity', - guide = 'legend') { +scale_pattern_rot_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = c(0, 360), + transform = 'identity', + guide = 'legend') { if (is.null(range)) { @@ -980,7 +980,7 @@ scale_pattern_rot_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) } diff --git a/data-raw/generate-scales-continuous-discrete.R b/data-raw/generate-scales-continuous-discrete.R index 6f17976..a1462a0 100644 --- a/data-raw/generate-scales-continuous-discrete.R +++ b/data-raw/generate-scales-continuous-discrete.R @@ -7,7 +7,7 @@ template_cont_roxygen_first <- " #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ #' Scales for continuous pattern aesthetics #' -#' @param name,breaks,labels,limits,range,trans,guide,... See +#' @param name,breaks,labels,limits,range,transform,guide,... See #' \\code{{ggplot2}} documentation for more information on scales. #' #' @return A [ggplot2::Scale] object. @@ -45,13 +45,13 @@ template_cont_var_cont_aes <- " #' @rdname scale_continuous #' @export #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -scale_{aes_name}_continuous <- function(name = waiver(), - breaks = waiver(), - labels = waiver(), - limits = NULL, - range = {scale_default}, - trans = 'identity', - guide = 'legend') {{ +scale_{aes_name}_continuous <- function(name = waiver(), + breaks = waiver(), + labels = waiver(), + limits = NULL, + range = {scale_default}, + transform = 'identity', + guide = 'legend') {{ if (is.null(range)) {{ @@ -65,7 +65,7 @@ scale_{aes_name}_continuous <- function(name = waiver(), breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide ) }} @@ -99,7 +99,7 @@ template_discrete_roxygen_first <- " #' Scales for discrete pattern aesthetics #' #' @param choices vector of values to choose from. -#' @param name,breaks,labels,limits,trans,guide,... See +#' @param name,breaks,labels,limits,transform,guide,... See #' \\code{{ggplot2}} documentation for more information on scales. #' #' @return A [ggplot2::Scale] object. @@ -136,7 +136,7 @@ template_cont_var_discrete_aes <- " #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ scale_{aes_name}_continuous <- function(name = waiver(), breaks = waiver(), labels = waiver(), limits = NULL, choices = {scale_default}, - trans = 'identity', guide = 'legend') {{ + transform = 'identity', guide = 'legend') {{ if (is.null(choices)) {{ @@ -150,7 +150,7 @@ scale_{aes_name}_continuous <- function(name = waiver(), breaks = waiver(), labe breaks = breaks, labels = labels, limits = limits, - trans = trans, + transform = transform, guide = guide) }} diff --git a/man/scale_continuous.Rd b/man/scale_continuous.Rd index cc0516e..37f6267 100644 --- a/man/scale_continuous.Rd +++ b/man/scale_continuous.Rd @@ -34,7 +34,7 @@ scale_pattern_angle_continuous( labels = waiver(), limits = NULL, range = c(0, 90), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -46,7 +46,7 @@ scale_pattern_density_continuous( labels = waiver(), limits = NULL, range = c(0, 0.5), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -58,7 +58,7 @@ scale_pattern_spacing_continuous( labels = waiver(), limits = NULL, range = c(0.01, 0.1), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -70,7 +70,7 @@ scale_pattern_xoffset_continuous( labels = waiver(), limits = NULL, range = c(0.01, 0.1), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -82,7 +82,7 @@ scale_pattern_yoffset_continuous( labels = waiver(), limits = NULL, range = c(0.01, 0.1), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -94,7 +94,7 @@ scale_pattern_aspect_ratio_continuous( labels = waiver(), limits = NULL, range = c(0.5, 2), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -106,7 +106,7 @@ scale_pattern_key_scale_factor_continuous( labels = waiver(), limits = NULL, range = c(0.5, 2), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -118,7 +118,7 @@ scale_pattern_scale_continuous( labels = waiver(), limits = NULL, range = c(0.5, 2), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -130,7 +130,7 @@ scale_pattern_phase_continuous( labels = waiver(), limits = NULL, range = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -142,7 +142,7 @@ scale_pattern_frequency_continuous( labels = waiver(), limits = NULL, range = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -154,7 +154,7 @@ scale_pattern_res_continuous( labels = waiver(), limits = NULL, range = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -166,14 +166,14 @@ scale_pattern_rot_continuous( labels = waiver(), limits = NULL, range = c(0, 360), - trans = "identity", + transform = "identity", guide = "legend" ) scale_pattern_rot_discrete(..., range = c(0, 360)) } \arguments{ -\item{name, breaks, labels, limits, range, trans, guide, ...}{See +\item{name, breaks, labels, limits, range, transform, guide, ...}{See \code{{ggplot2}} documentation for more information on scales.} } \value{ diff --git a/man/scale_discrete.Rd b/man/scale_discrete.Rd index 8e030bd..44a7fa2 100644 --- a/man/scale_discrete.Rd +++ b/man/scale_discrete.Rd @@ -26,7 +26,7 @@ scale_pattern_continuous( labels = waiver(), limits = NULL, choices = c("stripe", "crosshatch", "circle"), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -42,7 +42,7 @@ scale_pattern_type_continuous( labels = waiver(), limits = NULL, choices = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -54,7 +54,7 @@ scale_pattern_subtype_continuous( labels = waiver(), limits = NULL, choices = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -66,7 +66,7 @@ scale_pattern_filename_continuous( labels = waiver(), limits = NULL, choices = NULL, - trans = "identity", + transform = "identity", guide = "legend" ) @@ -78,7 +78,7 @@ scale_pattern_filter_continuous( labels = waiver(), limits = NULL, choices = c("lanczos", "box", "spline", "cubic"), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -95,7 +95,7 @@ scale_pattern_gravity_continuous( limits = NULL, choices = c("center", "north", "south", "east", "west", "northeast", "northwest", "southeast", "southwest"), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -112,7 +112,7 @@ scale_pattern_orientation_continuous( labels = waiver(), limits = NULL, choices = c("horizontal", "vertical", "radial"), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -128,7 +128,7 @@ scale_pattern_grid_continuous( labels = waiver(), limits = NULL, choices = c("square", "hex"), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -139,7 +139,7 @@ scale_pattern_grid_discrete( ) } \arguments{ -\item{name, breaks, labels, limits, trans, guide, ...}{See +\item{name, breaks, labels, limits, transform, guide, ...}{See \code{{ggplot2}} documentation for more information on scales.} \item{choices}{vector of values to choose from.} diff --git a/man/scale_pattern_size_continuous.Rd b/man/scale_pattern_size_continuous.Rd index f71ccb4..01000e7 100644 --- a/man/scale_pattern_size_continuous.Rd +++ b/man/scale_pattern_size_continuous.Rd @@ -13,7 +13,7 @@ scale_pattern_size_continuous( labels = waiver(), limits = NULL, range = c(1, 6), - trans = "identity", + transform = "identity", guide = "legend" ) @@ -23,12 +23,12 @@ scale_pattern_size( labels = waiver(), limits = NULL, range = c(1, 6), - trans = "identity", + transform = "identity", guide = "legend" ) } \arguments{ -\item{name, breaks, labels, limits, trans, guide}{See \code{ggplot2::scale_size} for more information} +\item{name, breaks, labels, limits, transform, guide}{See \code{ggplot2::scale_size} for more information} \item{range}{a numeric vector of length 2 that specifies the minimum and maximum size of the plotting symbol after transformation.}