question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Matplotlib 2.1 breaks Bayesian Blocks histogram

See original GitHub issue

You can see this difference between the stable and latest astropy docs:

With matplotlib 2.0:

histogram-3

With matplotlib 2.1:

histogram-3-1

I suspect matplotlib has somehow changed the internals of how the normed=True machinery works, in a way that only manifests if bins are unequal sized.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

3reactions
jakevdpcommented, Oct 24, 2017

Seems to be somehow related to matplotlib introducing the density argument to replace the normed argument, due to some changes in how numpy handles these arguments upstream. I’ll wait for advice from the matplotlib devs before doing any fix.

2reactions
jakevdpcommented, Oct 27, 2017

Fixes & regression tests are now merged into the 2.1.x matplotlib branch, and this will be fixed in the next bugfix release (I’m not certain when that is planned).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Feature Binning using Bayesian Blocks - Kaggle
Bayesian blocks is essentially a method creating histograms with bin sizes that adapt ... kwarg was deprecated in Matplotlib 2.1 and will be...
Read more >
Bayesian Blocks for Histograms — astroML 1.0 documentation
Bayesian Blocks is a dynamic histogramming method which optimizes one of several possible fitness functions to determine an optimal binning for data, ...
Read more >
histogramming.pdf - CERN Indico
A 'histogram is a collection of 1+ axes and an accumulator. Performance. • Variable axis - list of edges is most general but...
Read more >
matplotlib.pyplot.show — Matplotlib 2.1.2 documentation
In non-interactive mode, display all figures and block until the figures have been closed; in interactive mode it has no effect unless figures...
Read more >
Constructing plugins from TimeSeries - 3ML - Read the Docs
Bayesian Blocks (event lists). Constant Cadence . Constant cadence bins are defined by a start and a stop time along with a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found