Plotly Versions Save

An interactive graphing library for R

v4.10.4

3 months ago

Improvements

  • ggplotly() now works better with the development version of ggplot2 (> v3.4.4). (#2315)

v4.10.3

6 months ago

Improvements

  • ggplotly() now works better with the development version of ggplot2 (> v3.4.3). (#2301)

Bug fixes

  • Closed #1947: ggplotly() now correctly handles geom_vline/geom_hline with empty data. Previously, if geom_vline/geom_hline was passed an empty data frame, it would result in an error. The plot is drawn even if no lines are found; this is the same behavior as ggplot2.

  • Closed #1214: Do not warn in RStudio on Windows when scattergl is used. Recent RStudio versions can render scattergl correctly.

  • Closed #2298: Fix fill assignment in geom_point when a single shape value was used with multiple fill and colour values mapped (@zeehio)

v4.10.2

10 months ago

New features

  • Closed #2216: Additional selectize.js options can now be passed along to highlight()'s selectize argument. (#2217)

Improvements

  • Closed #2259: ggplotly() now provides better support for ggplot2 >v3.4.2. (#2262)

Bug fixes

  • Closed #2212: ggplotly() no longer silently drops legends that are customized through ggplot2::guide_legend().
  • Closed #2179: save_image() no longer needs reticulate::py_run_string("import sys") in order to run without error. (#2179)
  • Closed #2218: highlight(selectize = TRUE) no longer yields an incorrect selectize.js result when there is a combination of crosstalk and non-crosstalk traces. (#2217)
  • Closed #2208: ggplotly() no longer errors given a geom_area() with 1 or less data points (error introduced by new behavior in ggplot2 v3.4.0). (#2209)
  • Closed #2220: ggplotly() no longer errors on stat_summary(geom = "crossbar"). (#2222)
  • Closed #2212: ggplotly() no longer removes legends when setting guide properties via guides(aes = guide_xxx(...)).

v4.10.1

1 year ago

Changes to plotly.js

  • This version of the R package upgrades the version of the underlying plotly.js library from v2.5.1 to v2.11.1. This includes many bug fixes and improvements. The plotly.js release page has the full list of changes.

New features

  • plotlyOutput() gains a new fill parameter. When TRUE (the default), the widget's container element is allowed to grow/shrink to fit it's parent container so long as that parent is opinionated about its height and has been marked with htmltools::bindFillRole(x, container = TRUE). (#2198)
  • ggplotly() now supports the {ggalluvial} package. (#2061, thanks @moutikabdessabour)
  • highlight() now supports on="plotly_selecting", enabling client-side linked brushing via mouse click+drag (no mouse-up event required, as with on="plotly_selected"). (#1280)
  • raster2uri() supports nativeRaster objects. This enables nativeRaster support for the annotation_raster() geom (#2174, @zeehio).

Bug fixes

  • ggplotly() now converts stat_ecdf() properly. (#2065)
  • ggplotly() now correctly handles geom_tile() with no fill aesthetic. (#2063)
  • ggplotly() now respects guide(aes = "none") (e.g., guide(fill = "none")) when constructing legend entries. (#2067)
  • Fixed an issue with translating GGally::ggcorr() via ggplotly(). (#2012)
  • Fixed an issue where clearing a crosstalk filter would raise an error in the JS console (#2087)
  • Fixed an issue where map_color() would throw an error on R 4.2 (#2131)

Improvements

  • ggplotly() does not issue warnings with options(warnPartialMatchArgs = TRUE) any longer. (#2046, thanks @bersbersbers)
  • ggplotly() does not issue warnings related to use of deprecated tidyr::gather_() in internals. (#2125, thanks @simonpcouch)

v4.10.0

2 years ago

Breaking changes in JavaScript API

  • This version of the R package upgrades the version of the underlying plotly.js library from v1.57.1 to v2.5.1. This includes many breaking changes, bug fixes, and improvements to the underlying JavaScript library. Most of the breaking changes are summarized in this announcement of the 2.0 release, but see here for the full changelog.

Breaking changes in R API

  • ggplotly() now uses the layout.legend.title (instead of layout.annotations) plotly.js API to convert guides for discrete scales. (#1961)
  • renderPlotly() now uses Plotly.react() (instead of Plotly.newPlot()) to redraw when layout(transition = ) is specified. This makes it possible/easier to implement a smooth transitions when renderPlotly() gets re-executed. (#2001)

New Features

  • Added new functions for static image exporting via the kaleido python package, namely save_image() and kaleido(). See help(save_image, package = "plotly") for installation info and example usage. (#1971)

Improvements

  • ggplotly() now better positions axis titles for facet_wrap()/facet_grid(). (#1975)

v4.9.4.1

2 years ago
  • Fixes a bug in ggplotly() with {crosstalk} and {ggplot2} v3.3.4 (#1952).

v4.9.4

2 years ago

BUG FIXES

  • Duplicate highlight(selectize=T) dropdowns are no longer rendered in Shiny (#1936).
  • group_by.plotly() now properly retains crosstalk information across {dplyr} versions (#1920).
  • Adds fixes in ggplotly() for the upcoming {ggplot2} >3.3.3 release (#1952).
  • Fixes some issues with name and frames when both attributes are specified. (#1903 and #1618).

v4.9.3

3 years ago

Changes to plotly.js

  • This version of the R package upgrades the version of the underlying plotly.js library from v1.52.2 to v1.57.1. This includes many bug fixes and improvements. The plotly.js release page has the full list of changes.

NEW FEATURES

  • renderPlotly() now works well with shiny::bindCache(), meaning that plotly graphs can now be persistently cached in Shiny apps with renderPlotly(expr) %>% shiny::bindCache() (#1879).

  • ggplotly() now works well with the thematic package. That is, it can now correctly translate ggplot2 styling that derives from thematic. Note that, in order to use thematic's auto theming in Shiny with ggplotly(), you need shiny v1.5.0 (or higher) and htmlwidgets v1.5.2.9000 (or higher). Relatedly, if these versions are available, one may now also call getCurrentOutputInfo() inside renderPlotly() to get CSS styles of the output container (#1801 and #1802).

IMPROVEMENTS

  • All HTTP requests are now retried upon failure (#1656, @jameslamb).

  • R linebreaks (\n) in factor labels are now translated to HTML linebreaks (<br />), too. Before, this conversion was only done for colums of type character. (#1700, @salim-b).

BUG FIXES

  • When R's POSIXt class is serialized to JSON, the time of day is now correctly preserved (in plotly.js expected 'yyyy-mm-dd HH:MM:SS.ssssss' format). This should fix a whole host of issues where date-times were being rounded. (#1871, @FlukeAndFeather).

  • ggplotly() now handles discrete axes of a facet_wrap and facet_grid correctly when there is only one category in panels > 1 (#1577 and #1720).

  • ggplotly() now correctly accounts for linebreaks in tick label text when computing plot margins (#1791, @trekonom).

  • ggplotly() now handles element_blank() and factor() labels in positional scales correctly (#1731 and #1772).

  • ggplotly() now handles missing y aesthetic in geom_errorbar() (#1779, @trekonom).

v4.9.2

4 years ago

Changes to plotly.js

  • This version of the R package upgrades the version of the underlying plotly.js library from v1.49.4 to v1.52.2. This includes many bug fixes, improvements, as well as 2 new trace types: treemap and image. The plotly.js release page has the full list of changes.

IMPROVEMENTS

  • The add_image() function was added to make it easier to create image traces via raster objects.

BUG FIXES

  • add_sf()/geom_sf() now correctly handle geometry columns that are named something other than "geometry" (#1659).
  • Specifying an english locale no longer results in error (#1686).

v4.9.1

4 years ago

Changes to plotly.js

  • This version of the R package upgrades the version of the underlying plotly.js library from v1.46.1 to v1.49.4. The plotly.js release page has the full list of changes.

IMPROVEMENTS

  • event_data() gains support for the plotly_sunburstclick event (#1648)

BUG FIXES

  • Fixed an issue with correctly capturing the return value of user-expressions to renderPlotly() (#1528).
  • Fixed a resizing issue where graphs could be incorrectly resized to their initial size in some cases (#1553).
  • ggplotly() now positions the x-axis in the last column of a facet_wrap() properly (#1501).
  • ggplotly() now handles geom_hline()/geom_vline() correctly in conjunction with coord_flip() (#1519).
  • event_data() now correctly relays the key attribute for statistical traces (#1610).