# matplotlib output not showing in jupyter notebook with qiime2 environment

**URL:** https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846
**Category:** Other Bioinformatics Tools
**Tags:** python-api
**Created:** [April 22, 2022, 7:45am UTC](https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846 "2022-04-22T07:45:35Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Marsel\_Murzabaev](https://forum.qiime2.org/user_avatar/forum.qiime2.org/marsel_murzabaev/32/13252_2.png) [@Marsel\_Murzabaev](https://forum.qiime2.org/u/Marsel_Murzabaev)
#### Post date: [April 22, 2022, 7:45am UTC](https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846/1 "2022-04-22T07:45:36Z")

</div>

Hello,

I am mostly using qiime2 via python API in jupyter notebook.  
Great to have all commands and visualizations on one page.  
The problem is I cannot see usual plots from matplotlib on the same notebook with qiime2 visualizations.

The output looks like this:

1. \<seaborn.axisgrid.FacetGrid at 0x7f8bae852c70\>
2. AxesSubplot:ylabel='ID'  
and plt.show() does nothing.

What I do now is saving figures and check them in another tab.  
Same things occur in qiime2-2020.6 and later versions up to 2022.2 environments,  
last one freshly installed.  
Figures are displayed when I use matplotlib in non-qiime2 environments.  
Any thoughts what may be causing it and way around it?

Best regards,  
Marsel

---

<div class="post-metadata">

### Author: ![timanix](https://forum.qiime2.org/user_avatar/forum.qiime2.org/timanix/32/17879_2.png) [@timanix](https://forum.qiime2.org/u/timanix)
#### Post date: [April 22, 2022, 7:52am UTC](https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846/2 "2022-04-22T07:52:01Z")

</div>

Hi!  
I moved your questions to 'Other bioinformatics tools' section since it is related more to Jupyter notebooks rather than qiime2 issues.  
I use matplotlib inside if Qiime2 environments quite often via Jupyter lab, no problems so far.  
Just in case - did you try to put `%matplotlib inline` somewhere when importing libraries?

---

<div class="post-metadata">

### Author: ![Marsel\_Murzabaev](https://forum.qiime2.org/user_avatar/forum.qiime2.org/marsel_murzabaev/32/13252_2.png) [@Marsel\_Murzabaev](https://forum.qiime2.org/u/Marsel_Murzabaev)
#### Post date: [April 23, 2022, 6:00am UTC](https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846/3 "2022-04-23T06:00:13Z")

</div>

Hello!

Thank you for the fast reply.  
It works!  
Somehow I thought it is deprecated because usually I don't have to type it.

---

<div class="post-metadata">

### Author: ![timanix](https://forum.qiime2.org/user_avatar/forum.qiime2.org/timanix/32/17879_2.png) [@timanix](https://forum.qiime2.org/u/timanix)
#### Post date: [April 23, 2022, 6:08am UTC](https://forum.qiime2.org/t/matplotlib-output-not-showing-in-jupyter-notebook-with-qiime2-environment/22846/4 "2022-04-23T06:08:30Z")

</div>

> [@Marsel\_Murzabaev](#):
>
> Somehow I thought it is deprecated because usually I don't have to type it.

I am not aware of it but probably in newer versions. I think you can't install the latest version of Jupyter inside of Qiime2 environment because of python version and other dependencies. It is why the same code works outside of environment but not showing figures inside.
