2

I want to implement a custom backend of matplotlib, so I want to read the code of backend of matplotlib for inline plotting in jupyter for reference. Can anyone point me the source code of that ? Thanks

1 Answer 1

4

You can get the used backend by:

%pylab inline matplotlib.get_backend() >> 'module://ipykernel.pylab.backend_inline' 

Looking at the sourcecode in that module shows that the backend is imported from matplotlib.backends.backend_agg

The help for matplotlibrc file also has some information for specifying a new backend.

# The default backend; one of GTK GTKAgg GTKCairo GTK3Agg GTK3Cairo # MacOSX Qt4Agg Qt5Agg TkAgg WX WXAgg Agg Cairo GDK PS PDF SVG # Template. # You can also deploy your own backend outside of matplotlib by # referring to the module name (which must be in the PYTHONPATH) as # 'module://my_backend'. backend : qt5agg 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.