plot
Functions for plotting data.
The functions in this module are simple wrappers around plotting functions of matplotlib.
This module is not directly accessible from mdtools, but must be loaded explicitly e.g. via:
import mdtools.plot as mdtplt
This module loads the custom matplotlib style sheet
src/mdtools/pkg_data/mdtools.mplstyle
. If you want to keep the
default plotting style, you have to re-load the default style after
importing mdtools.plot
:
import matplotlib.pyplot as plt
plt.style.use("default")
See Customizing Matplotlib with style sheets and rcParams for more
information about style sheets. Among other settings,
mdtools.mplstyle
sets the default figure size to 8.26772 x
5.82677 inches, which is the size of a DIN A5 paper in landscape format.
The default font size is set to 24 points and also the line widths and
marker sizes are scaled appropriately. In this way the produced figures
can be used for presentations and posters or they can be scaled down to
the width of a single text column in a scientific journal without
loosing readability.
With the introduction of the mdtools.mplstyle
style sheet during
preparation of version 0.0.1.0, a lot of functions in this module became
deprecated, because the functions were just wrappers around
corresponding matplotlib functions with hardcoded style settings. With
the style sheet, the matplotlib functions can be called directly and
create plots with the desired style.
Todo
Update deprecated plot functions in the plot scripts.
Remove the deprecated plot functions in this module.
Functions
Annotate a heatmap. |
|
Create a correlogram and plot it to the given |
|
Plot data to a |
|
Fill the area between two curves y1 and y2 using |
|
Fill the area between two vertical curves x1 and x2 using |
|
Plot a histogram to a |
|
Plot horizontal lines at each y from start to stop into a |
|
Plot two dimensional data as heatmap with |
|
Plot two dimensional data as colormap with |
|
Plot a two dimensional matrix as heatmap with |
|
Plot two dimensional data as colormap with |
|
Plot two dimensional data as heatmap with |
|
Plot two dimensional data as colormap with |
|
Plot data to a |
|
Plot data to a second x-axis. |
|
Plot data to a second y-axis. |
|
Add a scatter plot to a |
|
Convert a number to scientific notation in TeX format. |
|
Plot vertical lines at each x from start to stop into a |
Classes
Class to define your own colorbar normalization. |