0
$\begingroup$

I am trying to create a bar plot for a Pandas Series and the bar plot is not showing up in Jupyter notebook.

When I run the cell, I only get the following and I do not see the bar plot.

<matplotlib.figure.Figure at 0x7fa555abc080>

Please advise.

Attached screenshot for your reference

$\endgroup$
2
  • 2
    $\begingroup$ you likely need to add "%matplotlib inline" to your code (stick it before or after the import statements, and without speech marks). $\endgroup$
    – sk877
    Jun 24 at 20:28
  • $\begingroup$ @sk877 Thank you! It worked. $\endgroup$ Jun 24 at 20:31
0
$\begingroup$

Try adding the %matplotlib magic function in your notebook, before the plot function, preferably in the beginning. This will enable the inline backend for usage with the IPython Notebook:

import pandas as pd
import matplotlib.pyplot as plt

%matplotlib inline


<your code here>
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.