Backends for plotting with SymPy
Project description
Sympy Plotting Backends
This module contains a few plotting backends that can be used with SymPy and Numpy. A backend represents the plotting library: it provides the necessary functionalities to quickly and easily plot the most common types of symbolic expressions (line plots, surface plots, parametric plots, vector plots, complex plots, control system plots).
The following plotting libraries are supported: Matplolib, Plotly, Bokeh, K3D-Jupyter, Mayavi.
What's new in comparison to SymPy
On top of the usual plotting functions exposed by SymPy (plot
,
plot_parametric
, plot3d
, etc.), this module offers the capabily to:
- use a different plotting library.
- visualize discontinuities on 2D line plots.
- visualize 2D/3D vector fields with quivers or streamlines.
- visualize complex functions with domain coloring.
- visualize entities from the
sympy.geometry
module. - visualize control systems' response to input signals, visualize Bode, Nyquist and Nichols plots.
- create parametric-interactive plots using widgets (sliders, buttons, etc.) with ipywidgets or Holoviz's Panel.
- combine multiple plots into a grid-like layout.
Please, read the
following documentation page
to understand the differences between this module and sympy.plotting
.
If you feel like some feature could be implemented, open an issue or create a PR.
Explore the Capabilities
Read the documentation to explore the capabilities before the installation, which contains plenty of examples.
Installation
SymPy Plotting Backends can be installed with pip
or conda
. By default,
only basic plotting with Matplotlib will be installed:
pip install sympy_plot_backends
Or
conda install -c conda-forge sympy_plot_backends
To install the complete requirements in order to get interactive plots, bokeh, plotly, k3d, vtk, execute the following command:
pip install sympy_plot_backends[all]
Or:
conda install -c anaconda scipy notebook colorcet
conda install -c conda-forge adaptive
conda install -c conda-forge panel
conda install -c anaconda ipywidgets
conda install -c conda-forge ipympl
conda install -c bokeh ipywidgets_bokeh
conda install -c conda-forge k3d msgpack-python
conda install -c plotly plotly
conda install -c conda-forge vtk
Finally, if you are using zshell, the above pip
command is going to fail.
Use the following instead:
pip install "sympy_plot_backends[all]"
Warnings
Some backend comes with a memory cost. Since they require external libraries and/or open a server-process in order to visualize the data, memory usage can quickly rise if we are showing many plots. Keep an eye on you system monitor and act accordingly (close the kernels, restart the browser, etc.).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for sympy_plot_backends-3.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e4de6c6cff7dcd2dfbb931228286b39fde0ef58af17e7ea63f148dd000f1602 |
|
MD5 | a760fcad9642c6dcc2063be6bb57491b |
|
BLAKE2b-256 | 86f5be80f19435f3e4f72962339ea6609668e07ebcc85d66479d389ae899b872 |
Hashes for sympy_plot_backends-3.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97a9c8f2624831635fc84d986e5795a9235b2329a6e00fb23554a5f504871b16 |
|
MD5 | 1ea295c42f901afdf9020a591118d1b2 |
|
BLAKE2b-256 | f7bac58df0ba3c6def5e5c0ae012a77b3180d88f25b4757e99de25d5acbb52aa |