Skip to content

Commit 5fe2514

Browse files
committed
Merge branch 'main' into position_aesthetics
2 parents 46a9ab0 + 859f618 commit 5fe2514

File tree

340 files changed

+6387
-3691
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

340 files changed

+6387
-3691
lines changed

.github/workflows/R-CMD-check.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
cache-version: 3
6464
extra-packages: >
6565
any::rcmdcheck,
66-
Hmisc=?ignore-before-r=4.1.0,
66+
Hmisc=?ignore-before-r=4.2.0,
6767
quantreg=?ignore-before-r=4.3.0
6868
needs: check
6969

DESCRIPTION

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: ggplot2
2-
Version: 3.5.1.9000
32
Title: Create Elegant Data Visualisations Using the Grammar of Graphics
3+
Version: 3.5.1.9000
44
Authors@R: c(
55
person("Hadley", "Wickham", , "[email protected]", role = "aut",
66
comment = c(ORCID = "0000-0003-4757-117X")),
@@ -30,21 +30,21 @@ License: MIT + file LICENSE
3030
URL: https://ggplot2.tidyverse.org, https://github.com/tidyverse/ggplot2
3131
BugReports: https://github.com/tidyverse/ggplot2/issues
3232
Depends:
33-
R (>= 3.5)
33+
R (>= 4.0)
3434
Imports:
3535
cli,
3636
grDevices,
3737
grid,
3838
gtable (>= 0.1.1),
3939
isoband,
4040
lifecycle (> 1.0.1),
41-
MASS,
4241
rlang (>= 1.1.0),
4342
scales (>= 1.3.0),
4443
stats,
4544
vctrs (>= 0.6.0),
4645
withr (>= 2.5.0)
4746
Suggests:
47+
broom,
4848
covr,
4949
dplyr,
5050
ggplot2movies,
@@ -53,6 +53,7 @@ Suggests:
5353
knitr,
5454
mapproj,
5555
maps,
56+
MASS,
5657
mgcv,
5758
multcomp,
5859
munsell,
@@ -75,6 +76,7 @@ VignetteBuilder:
7576
knitr
7677
Config/Needs/website: ggtext, tidyr, forcats, tidyverse/tidytemplate
7778
Config/testthat/edition: 3
79+
Config/usethis/last-upkeep: 2024-10-24
7880
Encoding: UTF-8
7981
LazyData: true
8082
Roxygen: list(markdown = TRUE)
@@ -125,15 +127,15 @@ Collate:
125127
'facet-grid-.R'
126128
'facet-null.R'
127129
'facet-wrap.R'
128-
'fortify-lm.R'
129130
'fortify-map.R'
130-
'fortify-multcomp.R'
131+
'fortify-models.R'
131132
'fortify-spatial.R'
132133
'fortify.R'
133134
'stat-.R'
134135
'geom-abline.R'
135136
'geom-rect.R'
136137
'geom-bar.R'
138+
'geom-tile.R'
137139
'geom-bin2d.R'
138140
'geom-blank.R'
139141
'geom-boxplot.R'
@@ -150,7 +152,6 @@ Collate:
150152
'geom-density2d.R'
151153
'geom-dotplot.R'
152154
'geom-errorbar.R'
153-
'geom-errorbarh.R'
154155
'geom-freqpoly.R'
155156
'geom-function.R'
156157
'geom-hex.R'
@@ -167,7 +168,6 @@ Collate:
167168
'geom-smooth.R'
168169
'geom-spoke.R'
169170
'geom-text.R'
170-
'geom-tile.R'
171171
'geom-violin.R'
172172
'geom-vline.R'
173173
'ggplot2-package.R'
@@ -254,6 +254,7 @@ Collate:
254254
'stat-ellipse.R'
255255
'stat-function.R'
256256
'stat-identity.R'
257+
'stat-manual.R'
257258
'stat-qq-line.R'
258259
'stat-qq.R'
259260
'stat-quantilemethods.R'
@@ -276,7 +277,6 @@ Collate:
276277
'utilities-break.R'
277278
'utilities-grid.R'
278279
'utilities-help.R'
279-
'utilities-matrix.R'
280280
'utilities-patterns.R'
281281
'utilities-resolution.R'
282282
'utilities-tidy-eval.R'

LICENSE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# MIT License
22

3-
Copyright (c) 2020 ggplot2 authors
3+
Copyright (c) 2024 ggplot2 core developer team
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

NAMESPACE

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,6 @@ S3method(guide_train,default)
8484
S3method(guide_transform,default)
8585
S3method(heightDetails,titleGrob)
8686
S3method(heightDetails,zeroGrob)
87-
S3method(interleave,default)
88-
S3method(interleave,unit)
8987
S3method(limits,Date)
9088
S3method(limits,POSIXct)
9189
S3method(limits,POSIXlt)
@@ -96,6 +94,7 @@ S3method(makeContext,dotstackGrob)
9694
S3method(merge_element,default)
9795
S3method(merge_element,element)
9896
S3method(merge_element,element_blank)
97+
S3method(merge_element,margin)
9998
S3method(pattern_alpha,GridPattern)
10099
S3method(pattern_alpha,GridTilingPattern)
101100
S3method(pattern_alpha,default)
@@ -126,8 +125,6 @@ S3method(scale_type,logical)
126125
S3method(scale_type,numeric)
127126
S3method(scale_type,ordered)
128127
S3method(scale_type,sfc)
129-
S3method(single_value,default)
130-
S3method(single_value,factor)
131128
S3method(summary,ggplot)
132129
S3method(vec_cast,character.mapped_discrete)
133130
S3method(vec_cast,double.mapped_discrete)
@@ -176,6 +173,7 @@ export(GeomAbline)
176173
export(GeomAnnotationMap)
177174
export(GeomArea)
178175
export(GeomBar)
176+
export(GeomBin2d)
179177
export(GeomBlank)
180178
export(GeomBoxplot)
181179
export(GeomCol)
@@ -267,6 +265,7 @@ export(StatEcdf)
267265
export(StatEllipse)
268266
export(StatFunction)
269267
export(StatIdentity)
268+
export(StatManual)
270269
export(StatQq)
271270
export(StatQqLine)
272271
export(StatQuantile)
@@ -426,6 +425,7 @@ export(get_alt_text)
426425
export(get_element_tree)
427426
export(get_geom_defaults)
428427
export(get_guide_data)
428+
export(get_labs)
429429
export(get_last_plot)
430430
export(get_layer_data)
431431
export(get_layer_grob)
@@ -463,10 +463,22 @@ export(guide_transform)
463463
export(guides)
464464
export(has_flipped_aes)
465465
export(is.Coord)
466+
export(is.coord)
466467
export(is.facet)
468+
export(is.geom)
467469
export(is.ggplot)
468470
export(is.ggproto)
471+
export(is.guide)
472+
export(is.guides)
473+
export(is.layer)
474+
export(is.mapping)
475+
export(is.margin)
476+
export(is.position)
477+
export(is.scale)
478+
export(is.stat)
469479
export(is.theme)
480+
export(is.theme_element)
481+
export(is.waiver)
470482
export(label_both)
471483
export(label_bquote)
472484
export(label_context)
@@ -484,6 +496,8 @@ export(layer_sf)
484496
export(lims)
485497
export(map_data)
486498
export(margin)
499+
export(margin_auto)
500+
export(margin_part)
487501
export(max_height)
488502
export(max_width)
489503
export(mean_cl_boot)
@@ -678,6 +692,7 @@ export(stat_ecdf)
678692
export(stat_ellipse)
679693
export(stat_function)
680694
export(stat_identity)
695+
export(stat_manual)
681696
export(stat_qq)
682697
export(stat_qq_line)
683698
export(stat_quantile)
@@ -711,6 +726,7 @@ export(theme_minimal)
711726
export(theme_replace)
712727
export(theme_set)
713728
export(theme_test)
729+
export(theme_transparent)
714730
export(theme_update)
715731
export(theme_void)
716732
export(transform_position)

NEWS.md

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,56 @@
33
* Position adjustments can now have auxiliary aesthetics (@teunbrand).
44
* `position_nudge()` gains `nudge_x` and `nudge_y` aesthetics (#3026, #5445).
55
* `position_dodge()` gains `order` aesthetic (#3022, #3345)
6+
* `guide_*()` can now accept two inside legend theme elements:
7+
`legend.position.inside` and `legend.justification.inside`, allowing inside
8+
legends to be placed at different positions. Only inside legends with the same
9+
position and justification will be merged (@Yunuuuu, #6210).
10+
* New stat: `stat_manual()` for arbitrary computations (@teunbrand, #3501)
11+
* Reversal of a dimension, typically 'x' or 'y', is now controlled by the
12+
`reverse` argument in `coord_cartesian()`, `coord_fixed()`, `coord_radial()`
13+
and `coord_sf()`. In `coord_radial()`, this replaces the older `direction`
14+
argument (#4021, @teunbrand).
15+
* `coord_radial()` displays minor gridlines now (@teunbrand).
16+
* (internal) `continuous_scale()` and `binned_scale()` sort the `limits`
17+
argument internally (@teunbrand).
18+
* Theme margins can have NA-units to inherit from parent elements. The new
19+
function `margin_part()` has NA-units as default (@teunbrand, #6115)
20+
* New `margin_auto()` specification for theme margins.
21+
* New argument `labs(dictionary)` to label based on variable name rather than
22+
based on aesthetic (@teunbrand, #5178)
23+
* Fixed bug in out-of-bounds binned breaks (@teunbrand, #6054)
24+
* Binned guides now accept expressions as labels (@teunbrand, #6005)
25+
* (internal) `Scale$get_labels()` format expressions as lists.
26+
* In non-orthogonal coordinate systems (`coord_sf()`, `coord_polar()` and
27+
`coord_radial()`), using 'AsIs' variables escape transformation when
28+
both `x` and `y` is an 'AsIs' variable (@teunbrand, #6205).
29+
* The following methods have been deprecated: `fortify.lm()`, `fortify.glht()`,
30+
`fortify.confint.glht()`, `fortify.summary.glht()` and `fortify.cld()`. It
31+
is recommend to use `broom::augment()` and `broom::tidy()` instead
32+
(@teunbrand, #3816).
33+
* Custom and raster annotation now respond to scale transformations, and can
34+
use AsIs variables for relative placement (@teunbrand based on
35+
@yutannihilation's prior work, #3120)
36+
* When discrete breaks have names, they'll be used as labels by default
37+
(@teunbrand, #6147).
38+
* The helper function `is.waiver()` is now exported to help extensions to work
39+
with `waiver()` objects (@arcresu, #6173).
40+
* Date(time) scales now throw appropriate errors when `date_breaks`,
41+
`date_minor_breaks` or `date_labels` are not strings (@RodDalBen, #5880)
42+
* `geom_errorbarh()` is deprecated in favour of
43+
`geom_errorbar(orientation = "y")` (@teunbrand, #5961).
44+
* `geom_contour()` should be able to recognise a rotated grid of points
45+
(@teunbrand, #4320)
46+
* `geom_boxplot()` gains additional arguments to style the colour, linetype and
47+
linewidths of the box, whiskers, median line and staples (@teunbrand, #5126)
48+
* (internal) Using `after_scale()` in the `Geom*$default_aes()` field is now
49+
evaluated in the context of data (@teunbrand, #6135)
50+
* Fixed bug where binned scales wouldn't simultaneously accept transformations
51+
and function-limits (@teunbrand, #6144).
52+
* Fixed bug where the `ggplot2::`-prefix did not work with `stage()`
53+
(@teunbrand, #6104).
54+
* New `get_labs()` function for retrieving completed plot labels
55+
(@teunbrand, #6008).
656
* Built-in `theme_*()` functions now have `ink` and `paper` arguments to control
757
foreground and background colours respectively (@teunbrand)
858
* The `summary()` method for ggplots is now more terse about facets
@@ -183,6 +233,19 @@
183233
* The ellipsis argument is now checked in `fortify()`, `get_alt_text()`,
184234
`labs()` and several guides (@teunbrand, #3196).
185235
* `stat_summary_bin()` no longer ignores `width` parameter (@teunbrand, #4647).
236+
* Added `keep.zeroes` argument to `stat_bin()` (@teunbrand, #3449)
237+
* (internal) removed barriers for using 2D structures as aesthetics
238+
(@teunbrand, #4189).
239+
* `coord_sf()` no longer errors when dealing with empty graticules (@teunbrand, #6052)
240+
* Added `theme_transparent()` with transparent backgrounds (@topepo).
241+
* New theme elements `palette.{aes}.discrete` and `palette.{aes}.continuous`.
242+
Theme palettes replace palettes in scales where `palette = NULL`, which is
243+
the new default in many scales (@teunbrand, #4696).
244+
* `guide_axis()` no longer reserves space for blank ticks
245+
(@teunbrand, #4722, #6069).
246+
* `geom_abline()` clips to the panel range in the vertical direction too
247+
(@teunbrand, #6086).
248+
* Added `panel.widths` and `panel.heights` to `theme()` (#5338, @teunbrand).
186249

187250
# ggplot2 3.5.1
188251

@@ -229,6 +292,7 @@ documentation updates.
229292
* `annotate()` now warns about `stat` or `position` arguments (@teunbrand, #5151)
230293
* `guide_coloursteps(even.steps = FALSE)` now works with discrete data that has
231294
been formatted by `cut()` (@teunbrand, #3877).
295+
* `ggsave()` now offers to install svglite if needed (@eliocamp, #6166).
232296

233297
# ggplot2 3.5.0
234298

0 commit comments

Comments
 (0)