Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Waterfall plot python?

Tags:

Is there a python module that will do a waterfall plot like MATLAB does? I googled 'numpy waterfall', 'scipy waterfall', and 'matplotlib waterfall', but did not find anything.

like image 227
Stripers247 Avatar asked Jun 26 '12 14:06

Stripers247


People also ask

How do you plot a waterfall in Python?

Simple Waterfall PlotUse the plot() function in waterfall_chart library to generate a waterfall chart. Values of x and y-axis should be passed as parameters into the function. Let's try to visualize a simple cash flow chart for whole year months.

What does a waterfall plot show?

Waterfall plots are an ordered histogram depicting the best percentage change in tumor size with positive values representing increase in size of tumor and negative values representing shrinkage of tumor. Each vertical column represents a single patient.

How do you create a stacked waterfall chart?

Create Waterfall and Stacked Waterfall chartsSelect the range of data. Click the Charts drop-down in the UpSlide ribbon. Click Waterfall (or press CTRL+Shift+B) If you update the data, the waterfall chart will update directly.


1 Answers

You can do a waterfall in matplotlib using the PolyCollection class. See this specific example to have more details on how to do a waterfall using this class.

Also, you might find this blog post useful, since the author shows that you might obtain some 'visual bug' in some specific situation (depending on the view angle chosen).

Below is an example of a waterfall made with matplotlib (image from the blog post): image
(source: austringer.net)

like image 167
gcalmettes Avatar answered Oct 28 '22 03:10

gcalmettes