1

I am running the latest versions of Python (3.5.2), IPython (6.1.0), and Jupyter (--version says 4.3.0 and pip3 shows 5.1.0) on Ubuntu.

Here is a quick example that illustrates the issue that appears in Jupyter. I changed the default figure.figsize in the matplotlibrc file.

import matplotlib
print(matplotlib.matplotlib_fname())
print(matplotlib.rcParams['figure.figsize'])

$USER/.config/matplotlib/matplotlibrc

[24.0, 13.5]

But as soon as I import the pyplot submodule, the parameters change back to default:

import matplotlib.pyplot as plt
print(matplotlib.matplotlib_fname())
print(matplotlib.rcParams['figure.figsize'])

$USER/.config/matplotlib/matplotlibrc

[6.0, 4.0]

Why is this happening and how can I use custom params together with plt?

My question might be similar to this issue that was not resolved.

sumtopmus
  • 29
  • 4
  • A question in the same direction with a more condensed answer, but focussing on the background instead of the figure size would be [this one](https://stackoverflow.com/questions/42656668/matplotlibrc-rcparams-modified-for-jupyter-inline-plots). – ImportanceOfBeingErnest Aug 08 '17 at 17:37
  • Thanks, all those links helped! – sumtopmus Aug 08 '17 at 22:01

0 Answers0