Changelog History
-
v0.11.0 Changes
September 08, 2020๐ This is a major release with important new features, enhancements to existing functions, and changes to the library. Highlights include an overhaul and modernization of the distributions plotting functions, more flexible data specification, new colormaps, and better narrative documentation.
๐ Complete release notes are available on the seaborn website.
-
v0.11.0.rc0 Changes
September 02, 2020๐ This is the first release candidate for v0.11.0, a major release with several important new features and changes to the library.
Highlights of the new version include:
- A modernization of the distributions module, with the introduction of
displot
,histplot
, andecdfplot
, a complete rewrite ofkdeplot
, and substantial enhancements tojointplot
andpairplot
- Centralized input data processing allowing for both standardization and increased flexibility of long- and wide-form variable specification
- ๐จ Substantial internal refactoring to support the new distributions functions and planned improvements in other modules
- โ Warning-based enforcement of keyword-only parameters in most functions
- ๐ New perceptually uniform colormaps and better tools for creating custom numeric color palettes
- ๐ Improvements to the narrative documentation, including user guide chapters on function types and data structures, along with better cross-linking within the seaborn docs and between the seaborn and matplotlib docs
- ๐ Numerous other targeted enhancements and bug fixes
๐ Please test the release by installing from here or with
python -m pip install --upgrade --pre seaborn
- A modernization of the distributions module, with the introduction of
-
v0.10.1 Changes
April 26, 2020๐ This is minor release with bug fixes for issues identified since 0.10.0.
- ๐ Fixed a bug that appeared within the bootstrapping algorithm on
32-bit systems. - ๐ Fixed a bug where
regplot
would crash on singleton inputs. Now a
crash is avoided and regression estimation/plotting is skipped. - ๐ Fixed a bug where
heatmap
would ignore user-specified
under/over/bad values when recentering a colormap. - ๐ Fixed a bug where
heatmap
would use values from masked cells when
0๏ธโฃ computing default colormap limits. - ๐ Fixed a bug where
despine
would cause an error when trying to trim
spines on a matplotlib categorical axis. - Adapted to a change in matplotlib that caused problems with single
swarm plots. - โ Added the
showfliers
parameter toboxenplot
to suppress plotting
of outlier data points, matching the API ofboxplot
. - ๐ Avoided seeing an error from statmodels when data with an IQR of 0
is passed tokdeplot
. - Added the
legend.title_fontsize
to theplotting_context
definition. - ๐ Deprecated several utility functions that are no longer used
internally (percentiles
,sig_stars
,pmf_hist
, andsort_df
).
- ๐ Fixed a bug that appeared within the bootstrapping algorithm on
-
v0.10.0 Changes
January 24, 2020๐ This is a major update that is being released simultaneously with version 0.9.1. It has all of the same features (and bugs!) as 0.9.1, but there are important changes to the dependencies.
๐ Most notably, all support for Python 2 has now been dropped. Support for Python 3.5 has also been dropped. Seaborn is now strictly compatible with Python 3.6+.
๐ Minimally supported versions of the dependent PyData libraries have also been increased, in some cases substantially. While seaborn has tended to be very conservative about maintaining compatibility with older dependencies, this was causing increasing pain during development. At the same time, these libraries are now much easier to install. Going forward, seaborn will likely stay close to the Numpy community guidelines for version support.
๐ This release also removes a few previously-deprecated features:
- ๐ The
tsplot
function andseaborn.timeseries
module have been removed. Recall thattsplot
was replaced withlineplot
. - ๐ The
seaborn.apionly
entry-point has been removed. - ๐ The
seaborn.linearmodels
module (previously renamed toseaborn.regression
) has been removed.
Looking forward
Now that seaborn is a Python 3 library, it can take advantage of keyword-only arguments. It is likely that future versions will introduce this syntax, potentially in a breaking way. For guidance, most seaborn functions have a signature that looks like
func(x, y, ..., data=None, **kwargs)
๐ where the
**kwargs
are specified in the function. Going forward it will likely be necessary to specifydata
and all subsequent arguments with an explicitkey=value
mapping. This style has long been used throughout the documentation, and the formal requirement will not be introduced until at least the next major release. Adding this feature will make it possible to enhance some older functions with more modern capabilities (e.g., adding a nativehue
semantic within functions likejointplot
andregplot
). - ๐ The
-
v0.10.0.rc0
January 24, 2020 -
v0.9.1 Changes
January 24, 2020๐ This is a minor release with a number of bug fixes and adaptations to changes in seaborn's dependencies. There are also several new features.
๐ This is the final version of seaborn that will support Python 2.7 or 3.5.
๐ New features
- Added more control over the arrangement of the elements drawn by
clustermap
with the{dendrogram,colors}_ratio
andcbar_pos
parameters. Additionally, the default organization and scaling with different figure sizes has been improved. - โ Added the
corner
option toPairGrid
andpairplot
to make a grid without the upper triangle of bivariate axes. - โ Added the ability to seed the random number generator for the bootstrap used to define error bars in several plots. Relevant functions now have a
seed
parameter, which can take either fixed seed (typically anint
) or a numpy random number generator object (either the newernumpy.random.Generator
or the oldernumpy.random.mtrand.RandomState
). - Generalized the idea of "diagonal" axes in
PairGrid
to any axes that share an x and y variable. - 0๏ธโฃ In
PairGrid
, thehue
variable is now excluded from the default list of variables that make up the rows and columns of the grid. - ๐ฆ Exposed the
layout_pad
parameter inPairGrid
and set a smaller default than what matptlotlib sets for more efficient use of space in dense grids. - ๐ It is now possible to force a categorical interpretation of the
hue
varaible in a relational plot by passing the name of a categorical palette (e.g."deep"
, or"Set2"
). This complements the (previously supported) option of passig a list/dict of colors. - โ Added the
tree_kws
parameter toclustermap
to control the properties of the lines in the dendrogram. - โ Added the ability to pass hierarchical label names to the
FacetGrid
legend, which also fixes a bug inrelplot
when the same label appeared in diffent semantics. - ๐ Improved support for grouping observations based on pandas index information in categorical plots.
๐ Bug fixes and adaptations
- โ Avoided an error when singular data is passed to
kdeplot
, issuing a warning instead. This makespairplot
more robust. - ๐ Fixed the behavior of
dropna
inPairGrid
to properly exclude null datapoints from each plot when set toTrue
. - ๐ Fixed an issue where
regplot
could interfere with other axes in a multi-plot matplotlib figure. - Semantic variables with a
category
data type will always be treated as categorical in relational plots. - โ Avoided a warning about color specifications that arose from
boxenplot
on newer matplotlibs. - 0๏ธโฃ Adapted to a change in how matplotlib scales axis margins, which caused multiple calls to
regplot
withtruncate=False
to progressively expand the x axis limits. Because there are currently limitations on how autoscaling works in matplotlib, the default value fortruncate
in seaborn has also been changed toTrue
. - Relational plots no longer error when hue/size data are inferred to be numeric but stored with a string datatype.
- Relational plots now consider semantics with only a single value that can be interpreted as boolean (0 or 1) to be categorical, not numeric.
- Relational plots now handle list or dict specifications for
sizes
correctly. - ๐ Fixed an issue in
pointplot
where missing levels of a hue variable would cause an exception after a recent update in matplotlib. - ๐ Fixed a bug when setting the rotation of x tick labels on a
FacetGrid
. - ๐ Fixed a bug where values would be excluded from categorical plots when only one variable was a pandas
Series
with a non-default index. - Fixed a bug when using
Series
objects as arguments forx_partial
ory_partial
inregplot
. - ๐ Fixed a bug when passing a
norm
object and using color annotations inclustermap
. - ๐ Fixed a bug where annotations were not rearranged to match the clustering in
clustermap
. - ๐ Fixed a bug when trying to call
set
while specifying a list of colors for the palette. - ๐ Fixed a bug when resetting the color code short-hands to the matplotlib default.
- Avoided errors from stricter type checking in upcoming
numpy
changes. - โ Avoided error/warning in
lineplot
when plotting categoricals with empty levels. - ๐ Allowed
colors
to be passed through to a bivariatekdeplot
. - Standardized the output format of custom color palette functions.
- ๐ Fixed a bug where legends for numerical variables in a relational plot could show a surprisingly large number of decimal places.
- ๐ Improved robustness to missing values in distribution plots.
- Made it possible to specify the location of the
FacetGrid
legend using matplotlib keyword arguments.
- Added more control over the arrangement of the elements drawn by
-
v0.9.1.rc0 Changes
January 22, 2020๐ First release candidate for v0.9.1
-
v0.9.0 Changes
July 16, 2018v0.9.0 (July 2018)
๐ Note: a version of these release notes with working links appears in the online documentation.
๐ This is a major release with several substantial and long-desired new features. There are also updates/modifications to the themes and color palettes that give better consistency with matplotlib 2.0 and some notable API changes.
๐ New relational plots
Three completely new plotting functions have been added: catplot, scatterplot, and lineplot. The first is a figure-level interface to the latter two that combines them with a FacetGrid. The functions bring the high-level, dataset-oriented API of the seaborn categorical plotting functions to more general plots (scatter plots and line plots).
๐ These functions can visualize a relationship between two numeric variables while mapping up to three additional variables by modifying
hue
,size
, and/orstyle
semantics. The common high-level API is implemented differently in the two functions. For example, the size semantic in scatterplot scales the area of scatter plot points, but in lineplot it scales width of the line plot lines. The API is dataset-oriented, meaning that in both cases you pass the variable in your dataset rather than directly specifying the matplotlib parameters to use for point area or line width.๐ Another way the relational functions differ from existing seaborn functionality is that they have better support for using numeric variables for
hue
andsize
semantics. This functionality may be propagated to other functions that can add ahue
semantic in future versions; it has not been in this release.๐ The lineplot function also has support for statistical estimation and is replacing the older
tsplot
function, which still exists but is marked for removal in a future release. lineplot is better aligned with the API of the rest of the library and more flexible in showing relationships across additional variables by modifying the size and style semantics independently. It also has substantially improved support for date and time data, a major pain factor intsplot
. The cost is that some of the more esoteric options intsplot
for representing uncertainty (e.g. a colormapped KDE of the bootstrap distribution) have not been implemented in the new function.๐ There is quite a bit of new documentation that explains these new functions in more detail, including detailed examples of the various options in the API reference and a more verbose tutorial.
๐ These functions should be considered in a "stable beta" state. They have been thoroughly tested, but some unknown corner cases may remain to be found. The main features are in place, but not all planned functionality has been implemented. There are planned improvements to some elements, particularly the default legend, that are a little rough around the edges in this release. Finally, some of the default behavior (e.g. the default range of point/line sizes) may change somewhat in future releases.
โก๏ธ Updates to themes and palettes
๐ Several changes have been made to the seaborn style themes, context scaling, and color palettes. In general the aim of these changes was to make the seaborn styles more consistent with the style updates in matplotlib 2.0 and to leverage some of the new style parameters for better implementation of some aspects of the seaborn styles. Here is a list of the changes:
- ๐ Reorganized and updated some axes_style/plotting_context parameters to take advantage of improvements in the matplotlib 2.0 update. The biggest change involves using several new parameterss in the "style" spec while moving parameters that used to implement the corresponding aesthetics to the "context" spec. For example, axes spines and ticks are now off instead of having their width/length zeroed out for the darkgrid style. That means the width/length of these elements can now be scaled in different contexts. The effect is a more cohesive appearance of the plots, especially in larger contexts. These changes include only minimal support for the 1.x matplotlib series. Users who are stuck on matplotlib 1.5 but wish to use seaborn styling may want to use the seaborn parameters that can be accessed through the matplotlib stylesheet interface.
- โก๏ธ Updated the seaborn palettes ("deep", "muted", "colorblind", etc.) to correspond with the new 10-color matplotlib default. The legacy palettes are now available at "deep6", "muted6", "colorblind6", etc. Additionally, a few individual colors were tweaked for better consistency, aesthetics, and accessibility.
- Calling color_palette (or set_palette) with a named qualitative palettes (i.e. one of the seaborn palettes, the colorbrewer qualitative palettes, or the matplotlib matplotlib tableau-derived palettes) and no specified number of colors will return all of the colors in the palette. This means that for some palettes, the returned list will have a different length than it did in previous versions.
- ๐ Enhanced color_palette to accept a parameterized specification of a cubehelix palette in in a string, prefixed with
"ch:"
(e.g."ch:-.1,.2,l=.7"
). Note that keyword arguments can be spelled out or referenced using only their first letter. Reversing the palette is accomplished by appending"_r"
, as with other matplotlib colormaps. This specification will be accepted by any seaborn function with apalette=
parameter. - Slightly increased the base font sizes in plotting_context and increased the scaling factors for
"talk"
and"poster"
contexts. - Calling set will now call set_color_codes to re-assign the single letter color codes by default
API changes
0๏ธโฃ A few functions have been renamed or have had changes to their default parameters.
- ๐ The
factorplot
function has been renamed to catplot. The new name ditches the original R-inflected terminology to use a name that is more consistent with terminology in pandas and in seaborn itself. This change should hopefully make catplot easier to discover, and it should make more clear what its role is.factorplot
still exists and will pass its arguments through to catplot with a warning. It may be removed eventually, but the transition will be as gradual as possible. - ๐
The other reason that the
factorplot
name was changed was to ease another alteration which is that the defaultkind
in catplot is now"strip"
(corresponding to stripplot). This plots a categorical scatter plot which is usually a much better place to start and is more consistent with the default in relplot. The old default style infactorplot
("point"
, corresponding to pointplot) remains available if you want to show a statistical estimation. - The
lvplot
function has been renamed to boxenplot. The "letter-value" terminology that was used to name the original kind of plot is obscure, and the abbreviation tolv
did not help anything. The new name should make the plot more discoverable by describing its format (it plots multiple boxes, also known as "boxen"). As withfactorplot
, thelvplot
function still exists to provide a relatively smooth transition. - ๐ Renamed the
size
parameter toheight
in multi-plot grid objects (FacetGrid, PairGrid, and JointGrid) along with functions that use them (factorplot
, lmplot, pairplot, and jointplot) to avoid conflicts with thesize
parameter that is used inscatterplot
andlineplot
(necessary to make relplot work) and also makes the meaning of the parameter a bit more clear. - ๐ Changed the default diagonal plots in pairplot to use
func
:kdeplotwhen a
"hue"` dimension is used. - ๐ Deprecated the statistical annotation component of JointGrid. The method is still available but will be removed in a future version.
- ๐ Two older functions that were deprecated in earlier versions,
coefplot
andinteractplot
, have undergone final removal from the code base.
๐ Documentation improvements
๐ There has been some effort put into improving the documentation. The biggest change is that the introduction to the library has been completely rewritten to provide much more information and, critically, examples. In addition to the high-level motivation, the introduction also covers some important topics that are often sources of confusion, like the distinction between figure-level and axes-level functions, how datasets should be formatted for use in seaborn, and how to customize the appearance of the plots.
Other improvements have been made throughout, most notably a thorough re-write of the categorical tutorial categorical_tutorial.
๐ Other small enhancements and bug fixes
- ๐ Changed rugplot to plot a matplotlib
LineCollection
instead of manyLine2D
objects, providing a big speedup for large arrays. - ๐ Changed the default off-diagonal plots to use scatterplot. (Note that the
"hue"
currently draws three separate scatterplots instead of using the hue semantic of the scatterplot function). - ๐ Changed color handling when using kdeplot with two variables. The default colormap for the 2D density now follows the color cycle, and the function can use
color
andlabel
kwargs, adding more flexibility and avoiding a warning when using with multi-plot grids. - โ Added the
subplot_kws
parameter to PairGrid for more flexibility. - โ Removed a special case in PairGrid that defaulted to drawing stacked histograms on the diagonal axes.
- ๐ Fixed jointplot/JointGrid and regplot so that they now accept list inputs.
- ๐ Fixed a bug in FacetGrid when using a single row/column level or using
col_wrap=1
. - ๐ Fixed functions that set axis limits so that they preserve auto-scaling state on matplotlib 2.0.
- Avoided an error when using matplotlib backends that cannot render a canvas (e.g. PDF).
- ๐ Changed the install infrastructure to explicitly declare dependencies in a way that
pip
is aware of. This means thatpip install seaborn
will now work in an empty environment. Additionally, the dependencies are specified with strict minimal versions. - โก๏ธ Updated the testing infrastructure to execute tests with pytest (although many individual tests still use nose assertion).
-
v0.8.1 Changes
September 03, 2017v0.8.1 (September 2017)
โ Added a warning in
FacetGrid
when passing a categorical plot function without specifyingorder
(orhue_order
whenhue
is used), which is likely to produce a plot that is incorrect.๐ Improved compatibility between
FacetGrid
orPairGrid
and interactive matplotlib backends so that the legend no longer remains inside the figure when usinglegend_out=True
.Changed categorical plot functions with small plot elements to use
dark_palette
instead oflight_palette
when generating a sequential palette from a specified color.๐ Improved robustness of
kdeplot
anddistplot
to data with fewer than two observations.๐ Fixed a bug in
clustermap
when usingyticklabels=False
.๐ Fixed a bug in
pointplot
where colors were wrong if exactly three points were being drawn.๐ Fixed a bug in
pointplot
where legend entries for missing data appeared with empty markers.๐ Fixed a bug in
clustermap
where an error was raised when annotating the main heatmap and showing category colors.๐ Fixed a bug in
clustermap
where row labels were not being properly rotated when they overlapped.๐ Fixed a bug in
kdeplot
where the maximum limit on the density axes was not being updated when multiple densities were drawn.๐ Improved compatibility with future versions of pandas.
-
v0.8.0 Changes
July 08, 2017๐ The default style is no longer applied when seaborn is imported. It is now necessary to explicitly call
set
or one or more ofset_style
,set_context
, andset_palette
. Correspondingly, theseaborn.apionly
module has been deprecated.๐ Changed the behavior of
heatmap
(and by extensionclustermap
) when plotting divergent dataesets (i.e. when thecenter
parameter is used). Instead of extending the lower and upper limits of the colormap to be symettrical around thecenter
value, the colormap is modified so that its middle color corresponds tocenter
. This means that the full range of the colormap will not be used (unless the data or specifiedvmin
andvmax
are symettric), but the upper and lower limits of the colorbar will correspond to the range of the data. See the Github pull request (#1184) for examples of the behavior.โ Removed automatic detection of diverging data in
heatmap
(and by extensionclustermap
). If you want the colormap to be treated as diverging (see above), it is now necessary to specify thecenter
value. When no colormap is specified, specifyingcenter
will still change the default to be one that is more appropriate for displaying diverging data.โ Added four new colormaps, created using viscm for perceptual uniformity. The new colormaps include two sequential colormaps (
"rocket"
and"mako"
) and two diverging colormaps ("icefire"
and"vlag"
). These colormaps are registered with matplotlib on seaborn input and the colormap objects can be accessed in theseaborn.cm
namespace.๐ Changed the default
heatmap
colormaps to be"rocket"
(in the case of sequential data) or"icefire"
(in the case of diverging data). Note that this change reverses the direction of the luminance ramp from the previous defaults. While potentially confusing and disruptive, this change better aligns the seaborn defaults with the new matplotlib default colormap ("viridis"
) and arguably better aligns the semantics of a "heat" map with the appearance of the colormap.โ Added
"auto"
as a (default) option for tick labels inheatmap
andclustermap
. This will try to estimate how many ticks can be labeled without the text objects overlapping, which should improve performance for larger matrices.โ Added the
dodge
parameter to boxplot, violinplot, and barplot to allow use ofhue
without changing the position or width of the plot elements, as when thehue
varible is not nested within the main categorical variable.Correspondingly, the
split
parameter for stripplot and swarmplot has been renamed tododge
for consistency with the other categorical functions (and for differentiation from the meaning ofsplit
in violinplot).Added the ability to draw a colorbar for a bivariate kdeplot with the
cbar
parameter (and relatedcbar_ax
andcbar_kws
parameters).โ Added the ability to use error bars to show standard deviations rather than bootstrap confidence intervals in most statistical functions by putting
ci="sd"
.๐ Allow side-specific offsets in
despine
.Figure size is no longer part of the seaborn plotting context parameters.
Put a cap on the number of bins used in
jointplot
fortype=="hex"
to avoid hanging when the reference rule prescribes too many.Turn off dendrogram axes in
clustermap
rather than setting the background color to white.๐ New matplotlib qualitative palettes (e.g.
"tab10"
) are now handled correctly.Some modules and functions have been internally reorganized; there should be no effect on code that uses the
seaborn
namespace.โ Added a deprecation warning to
tsplot
function to indicate that it will be removed or replaced with a substantially altered version in a future release.๐ The
interactplot
andcoefplot
functions are officially deprecated and will be removed in a future release.