Convert x value to symlog scale with zero shift using Python and matplotlib.pyplot


The result is:

Convert x value to symlog scale with zero shift using Python and matplotlib.pyplot

This code shows how to convert x value to symlog scale with zero shift using Python and matplotlib.pyplot

Two ways to align ylabels for two plots using Python and matplotlib.pyplot


The result is:

Two ways to align ylabels for two plots using Python and matplotlib.pyplot

This page shows two ways to align two ylabels for two subplots using Python and matplotlib.pyplot.

Generate figure with just only table using Python and matplotlib.pyplot


The result is:

Generate figure with just only table using Python and matplotlib.pyplot

This code shows how to generate a figure with just only a table using Python and matplotlib.pyplot

Generate network graph using Python and matplotlib.pyplot


The result is:


This page shows how to generate network graph using Python, matplotlib.pyplot and networkx.

Combine two figures with/without spines and ticks using Python and matplotlib.pyplot


The result is:

Combine two figures with/without spines and ticks using Python and matplotlib.pyplot

This code shows how to combine two figures with and without spines and ticks using Python and matplotlib.pyplot.

Remove ticks and spines (box around figure) using Python and maptlotlib.pyplot


The result is:

Remove ticks and spines (box around figure) using Python and maptlotlib.pyplot

This page shows how to remove ticks and spines (box around figure) using Python and matplotlib.pyplot.

Interactive figure with several 1D plot and one hovertools using Python and Bokeh


The result is:

Interactive figure with several 1D plot and one hovertools using Python and Bokeh

This code how to generate interactive figure with several 1D plot, one hovertools and togglable legend using Python and Bokeh. This is a continuing post of last one.

Interactive figure with several 1D plot and several hovertools using Python and Bokeh


The result is:

Interactive figure with several 1D plot and several hovertools using Python and Bokeh

This page shows how to generate interactive figure with several 1D plot and several hovertools using Python and Bokeh. The way to merge hovertools will be shown in the next post.

Interactive 1D time-scale plot with hovertool using Python and Bokeh


The result (static image) is:

Interactive 1D time-scale plot with hovertool using Python and Bokeh

This page shows how to generate interactive time-scale 1D line plot with hovertool (stock data) using Python and Bokeh.

Two-dimensional interactive contour plot with colorbar using Python and Bokeh


The result is:

Two-dimensional interactive contour plot with colorbar using Python and Bokeh

Add linear colorbar to the contourf using Python and Bokeh.

Two-dimensional interactive contour plot using Python and Bokeh


The result is:

Two-dimensional interactive contour plot using Python and Bokeh

Bokeh is powerful plotting tools using nodejs. Although this code doesn't use matplotlib, I want to introduce how to generate 2D interactive contour plot using Bokeh.

Interactive plot using Bokeh - first step -


The result (static image) is:

Interactive plot using Bokeh - first step -

I firstly thought that Bokeh uses matplotlib. We generate figure using matplotlib then convert the figure to the Bokeh compatible. However, it seems Bokeh works stand alone without matplotlib (is it true?) Anyway, let's check whether Bokeh works in my environment or not.

Interactive time-scale stock price figure using Python, matplotlib.pyplot and mpld3


The result (static image) is:

Interactive time-scale stock price figure using Python, matplotlib.pyplot and mpld3

This page shows how to generate interactive figure using python, matplotlib.pyplot and mpld3. The stock information of the apple.inc is used as the example to plot.

Interactive figure with interactive legend using Python, matplotlib.pyplot and mpld3


The result (static image) is:

Interactive figure with interactive legend using Python, matplotlib.pyplot and mpld3

This page shows how to plot data in interactive figure using python, matplotlib.pyplot and mpld3. A interactive legend is added to the figure.

Animate 3D wireframe using animation.FuncAnimation in Python and maptlotlib.pyplot


The result is:

Animate 3D wireframe using animation.FuncAnimation in Python and maptlotlib.pyplot

This page shows how to animate 3D wireframe figure using animation.FuncAnimation in Python and matplotlib.pyplot.

Generate animation of 3D surface plot using plot_surface and animation.ArtistAnimation in Python and matplotlib.pyplot


The result is:

Generate animation of 3D surface plot using plot_surface and animation.ArtistAnimation in Python and matplotlib.pyplot

This page shows how to generate an animation of 3D surface plot using plot_surface and animation.ArtistAnimation in python and matplotlib.pyplot.

Generate animation of 3D surface plot using plot_surface and animation.FuncAnimation in Python and matplotlib.pyplot


The result is:

Generate animation of 3D surface plot using plot_surface and animation.FuncAnimation in Python and matplotlib.pyplot


This page shows how to generate an animation of 3D surface plot using plot_surface and animation.Funcanimation in python and matplotlib.pyplot.

Generate 3D scatter animation using animation.FuncAnimation in Python and matplotlib.pyplot


The result is:

Generate 3D scatter animation using animation.FuncAnimation in Python and matplotlib.pyplot

This page shows how to generate 3D animation of scatter plot using animation.FuncAnimation, python, and matplotlib.pyplot.

Generate normalized stacked barplot with sample number and percentage using Python and matplotlib.pyplot


The result is:

Generate normalized stacked barplot with sample number and percentage using Python and matplotlib.pyplot

This page shows how to generate normalized stacked barplot with sample number of each bar and percentage of each data using python and matplotlib.pyplot.

Add sample number to stacked barplot using Python and matplotlib.pyplot


The result is:

Add sample number to stacked barplot using Python and matplotlib.pyplot


This page shows how to add sample number to stacked barplot using Python and matplotlib.pyplot.

Combine two contourf and one colorbar into one figure using Python and matplotlib.pyplot


The result is:
Combine two contourf and one colorbar into one figure using Python and matplotlib.pyplot

This page shows how to combine two contourf and one colorbar into one figure using python and matplotlib.pyplot.

Generate stacked barplot using Python and matplotlib.pyplot


The result is:

Generate stacked barplot using Python and matplotlib.pyplot

This page shows how to generate stacked barplot using Python and matplotlib.pyplot.

Plot contour figure from data which has large scale and plus-minus difference with minimum limit using Python and matplotlib.pyplot


The result is:

Plot contour figure from data which has large scale and plus-minus difference with minimum limit using Python and matplotlib.pyplot

This page shows my suggestion to generate contour figure from data which has large scale and plus-minus difference using python and matplotlib.pyplot. The minimum value and maximum value can be specified in this code.

Increase box size of the legend for barplot using Python and matplotlib.pyplot


The result is:

Increase box size of the legend for barplot using Python and matplotlib.pyplo

This page shows how to increase box size of the legend for barplots using Python and matplotlib.pyplot.