Create Elegant Data Visualisations Using the Grammar of Graphics
Overview
A system for 'declaratively' creating graphics, based on "The Grammar of Graphics". You provide the data, tell 'ggplot2' how to map variables to aesthetics, what graphical primitives to use, and it takes care of the details.
This is a hotfix release fixing a test, a bug and introducing a feature.
- Adapt to changes in
rlang::warn_dots_used()(@lionel-, #6830). - Fixed bug where
guide_axis_theta()didn't anticipate old-style text elements (#6803). geom_boxplot()/stat_boxplot()gain aquantile.typeparameter (default7) to control the percentile definition used for hinges and median; setquantile.type = 2to match SAS's defaultPCTLDEF = 5, enabling parity with SAS boxplots out-of-the-box. (@munoztd0, #6819)
From NEWS.md in the release
Install
Health
NOTER code for possible problemsr-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-x86_64
Found calls to structure() using deprecated special names: ggplot2/tests/testthat/test-annotate.R (.Names: 1) '.Names' should be changed to 'names'.
NOTERd contentsr-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc
Rd files without \usage: ‘print.ggplot.Rd’ \arguments should not be documented without \usage.
- NOTE8 OK, 5 NOTE2026-10-25
- ERROR8 OK, 4 NOTE, 1 ERROR2026-10-24
- NOTE12 OK, 1 NOTE2026-07-11
- OK13 OK2026-06-08
- WARNING12 OK, 1 WARNING2026-06-07
Show 3 earlier changesHide 3 earlier changes
- OK13 OK2026-04-30
- ERROR10 OK, 3 NOTE, 1 ERROR2026-04-07
- NOTE11 OK, 3 NOTE2026-03-10
Documentation
The repository also keeps web-only articles.
- Help pages
- 226 (87 internal)includes a package overview page
- Examples that run
- 93%148 run in a plain check (6 of them under a condition) · 8 only when donttest examples are enabled (R CMD check --as-cran) · 2 never run · 1 hold no code
- Exported functions with examples
- 76%
- Documented parameters
- 85%
- Return-value docs
- 21%
- Help pages citing references
- 2%
Downloads
Repository
- PRs merged (all time)
- 80%
- Median days to close, 50 most recently updated closed issues
- 86
- Median days to close, 50 most recently updated closed PRs
- 30
Stars over time
Forks over time
Releases over time
Issues over time
PRs over time
Commits over time
Commit identities over time
18 development-tooling and community-health practices detected across 8 families in the upstream repository
Checks run against github.com/tidyverse/ggplot2 on 2026-10-25.
The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel
GitHub Pages site last deployed 2026-10-20 · The repository has a site deploy workflow
pkgdown site last built 2026-04-22
Show all practicesHide 4 practices
An outside contributor's pull request to this repository was written with an AI coding tool.
- Claude CodePull requests: 1 from outside contributors, first on 2025-05-23, 1 from forks
Dependencies
Installing ggplot2 adds 16 packages (7 with compiled code, 7.6 MB of source tarballs). Heaviest: isoband 1.5 MB, farver 1.2 MB, viridisLite 1.2 MB.
Show the 48 most downloaded dependentsHide the 48 most downloaded dependents
and 4,957 more dependents and 2,154 packages that suggest it on CRAN ↗
Code & Tests
Datasets
People & History
Previously maintained by Hadley Wickham (0.5 to 3.3.1).
Pick two releases to compare their code metrics.
- RR 4.6.0 released · 2026-04-24
- 4.0.3Latest
- 4.0.22026-02-03 · diff ↗
- 4.0.12025-11-14 · diff ↗
- 4.0.02025-09-11 · diff ↗ ·
added 63 exports
CoordTransform, GeomBin2d, StatConnect, StatManual, add_gg, annotation_borders, class_S3_gg, class_coord, class_derive, class_facet, class_gg, class_ggplot, class_ggplot_built, class_ggproto, class_guide, class_guides, class_labels, class_layer, class_layout, class_mapping, class_rel, class_scale, class_scales_list, class_theme, class_waiver, class_zero_grob, complete_theme, coord_transform, element, element_geom and 33 more - RR 4.5.0 released · 2025-04-11
- 3.5.22025-04-09 · diff ↗ ·
added 17 exports
get_geom_defaults, get_labs, is_coord, is_facet, is_geom, is_ggplot, is_ggproto, is_guide, is_guides, is_layer, is_mapping, is_margin, is_position, is_scale, is_stat, is_theme, is_theme_element - RR 4.4.0 released · 2024-04-24
- 3.5.12024-04-23 · diff ↗
- 3.5.02024-02-23 · diff ↗ ·
added 27 exports
.expose_data, .ignore_data, CoordRadial, Guide, GuideAxis, GuideAxisLogticks, GuideAxisStack, GuideAxisTheta, GuideBins, GuideColourbar, GuideColoursteps, GuideCustom, GuideLegend, GuideNone, GuideOld, check_device, coord_radial, fill_alpha, get_guide_data, guide_axis_logticks, guide_axis_stack, guide_axis_theta, guide_custom, new_guide, old_guide, pattern_alpha, translate_shape_string - 3.4.42023-10-12 · diff ↗
- 3.4.32023-08-14 · diff ↗
- RR 4.3.0 released · 2023-04-21
- 3.4.2
- 3.4.1
- 3.4.02022-11-04 · diff ↗ ·
added 10 exports
StatAlign, draw_key_linerange, scale_linewidth, scale_linewidth_binned, scale_linewidth_continuous, scale_linewidth_date, scale_linewidth_datetime, scale_linewidth_discrete, scale_linewidth_ordinal, stat_align
Show 64 earlier eventsHide 64 earlier events
- 3.3.62022-05-03 · diff ↗
- RR 4.2.0 released · 2022-04-22
- 3.3.52021-06-25 · diff ↗
- 3.3.42021-06-16 · diff ↗ ·
added 5 exports
as_label, geom_bin_2d, get_alt_text, scale_color_viridis_b, sf_transform_xy - RR 4.1.0 released · 2021-05-18
- 3.3.32020-12-30 · diff ↗
- 3.3.22020-06-19 · diff ↗ ·
added 11 exports
GeomContourFilled, GeomDensity2dFilled, GeomFunction, StatDensity2dFilled, binned_scale, geom_density2d_filled, geom_density_2d_filled, geom_function, scale_alpha_binned, stat_density2d_filled, stat_density_2d_filled - 3.3.12020-05-29 · diff ↗
- RR 4.0.0 released · 2020-04-24
- 3.3.02020-03-05 · diff ↗ ·
added 49 exports
ScaleBinned, ScaleBinnedPosition, StatContourFilled, after_scale, after_stat, el_def, element_render, expansion, flip_data, flipped_names, geom_contour_filled, get_element_tree, guide_axis, guide_bins, guide_colorsteps, guide_coloursteps, guide_none, guide_transform, has_flipped_aes, register_theme_elements, reset_theme_settings, scale_color_binned, scale_color_date, scale_color_datetime, scale_color_fermenter, scale_color_ordinal, scale_color_steps, scale_color_steps2, scale_color_stepsn, scale_colour_binned and 19 more - 3.2.12019-08-11 · diff ↗
- 3.2.0
- RR 3.6.0 released · 2019-04-26
- 3.1.12019-04-07 · diff ↗
- 3.1.02018-10-25 · diff ↗ ·
added 5 exports
StatSfCoordinates, geom_sf_label, geom_sf_text, standardise_aes_names, stat_sf_coordinates - 3.0.02018-07-03 · diff ↗ ·
added 57 exports
.data, CoordSf, GeomSf, Layout, PositionDodge2, StatQqLine, StatSf, autolayer, coord_sf, enexpr, enexprs, enquo, enquos, ensym, ensyms, expand_scale, expr, geom_qq_line, geom_sf, ggplot_add, guide_gengrob, guide_geom, guide_merge, guide_train, merge_element, position_dodge2, quo, quo_name, quos, scale_alpha_date and 27 more - RR 3.5.0 released · 2018-04-23
- RR 3.4.0 released · 2017-04-21
- 2.2.12016-12-30 · diff ↗
- 2.2.02016-11-11 · diff ↗ ·
removed 1 export
facetadded 21 exports
AxisSecondary, Facet, FacetGrid, FacetNull, FacetWrap, GeomCol, combine_vars, derive, dup_axis, find_panel, geom_col, max_height, max_width, panel_cols, panel_rows, render_axes, render_strips, scale_x_time, scale_y_time, sec_axis, wrap_dims - RR 3.3.0 released · 2016-05-03
- 2.1.02016-03-01 · diff ↗ ·
added 7 exports
scale_colour_date, scale_colour_datetime, scale_fill_date, scale_fill_datetime, scale_size_date, scale_size_datetime, theme_replace - 2.0.02015-12-18 · diff ↗ ·
removed 20 exports
coord, ggfluctuation, ggmissing, ggorder, ggpcp, ggstructure, is.coord, opts, plotmatrix, scale_area, stat_abline, stat_bindot, stat_hline, stat_vline, theme_blank, theme_line, theme_rect, theme_segment, theme_text, update_elementadded 144 exports
.pt, .stroke, Coord, CoordCartesian, CoordFixed, CoordFlip, CoordMap, CoordPolar, CoordQuickmap, CoordTrans, Geom, GeomAbline, GeomAnnotationMap, GeomArea, GeomBar, GeomBlank, GeomBoxplot, GeomContour, GeomCrossbar, GeomCurve, GeomCustomAnn, GeomDensity, GeomDensity2d, GeomDotplot, GeomErrorbar, GeomErrorbarh, GeomHex, GeomHline, GeomLabel, GeomLine and 114 more - RR 3.2.0 released · 2015-04-16
- 1.0.12015-03-17 · diff ↗
- 1.0.02014-05-21 · diff ↗ ·
added 11 exports
aes_q, coord_quickmap, label_wrap_gen, labeller, position_jitterdodge, scale_color_distiller, scale_colour_distiller, scale_fill_distiller, stat_ellipse, theme_light, theme_linedraw - RR 3.1.0 released · 2014-04-10
- RR 3.0.0 released · 2013-04-03
- 0.9.3.12013-03-02 · diff ↗
- 0.9.3
- 0.9.2.12012-09-11 · diff ↗
- 0.9.22012-09-04 · diff ↗ ·
added 12 exports
%+replace%, calc_element, element_blank, element_line, element_rect, element_text, ggtitle, is.ggplot, is.theme, rel, stat_ecdf, theme - 0.9.1
- RR 2.15.0 released · 2012-03-30
- 0.9.02012-03-01 · diff ↗ ·
removed 1 export
pattern:^[^\\.]added 214 exports
%+%, aes_all, aes_auto, aes_string, aes, annotate, annotation_custom, annotation_map, annotation_raster, autoplot, benchplot, borders, continuous_scale, coord_cartesian, coord_equal, coord_fixed, coord_flip, coord_map, coord_polar, coord_trans, coord, cut_interval, cut_number, discrete_scale, expand_limits, facet_grid, facet_null, facet_wrap, facet, fortify and 184 more - RR 2.14.0 released · 2011-10-31
- RR 2.13.0 released · 2011-04-13
- 0.8.92010-12-23 · diff ↗
- RR 2.12.0 released · 2010-10-15
- 0.8.82010-07-05 · diff ↗
- RR 2.11.0 released · 2010-04-22
- 0.8.72010-03-02 · diff ↗
- 0.8.62010-02-18 · diff ↗
- 0.8.52009-12-16 · diff ↗
- 0.8.42009-12-09 · diff ↗
- RR 2.10.0 released · 2009-10-26
- 0.8.32009-04-20 · diff ↗
- RR 2.9.0 released · 2009-04-17
- 0.8.22009-02-25 · diff ↗
- 0.8.12008-12-14 · diff ↗
- 0.82008-11-21 · diff ↗
- RR 2.8.0 released · 2008-10-20
- 0.72008-10-05 · diff ↗
- RR 2.7.0 released · 2008-04-22
- 0.62008-04-03 · diff ↗
- 0.5.72008-01-11 · diff ↗
- 0.5.62007-10-20 · diff ↗
- RR 2.6.0 released · 2007-10-03
- 0.5.52007-09-01 · diff ↗
- 0.5.42007-07-08 · diff ↗
- 0.5.22007-06-18 · diff ↗
- 0.5.12007-06-10 · diff ↗
- 0.52007-06-01
- RR 2.5.0 released · 2007-04-24
Package metadata
- First published
- 2007-06-01
- Total releases
- 55 / 19 yrs
- License
- MIT + file LICENSE OSI · relicensed from GPL-2 | file LICENSE in 3.3.3
- Minimum R
- ≥ 4.1
- Bundled data
- 599 KB / 11 files
- Download size
- 6.0 MB
Cite
Cite this package
Run in R for the authors' entry:
citation("ggplot2")The package provides a citation file, so citation() returns the authors' own entry.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-26, which the citation names so these numbers can be found later. More on citing and the projects behind them.