pycharm python 3.7 matplotlib portrait has not presented

A little bit every day, work record in practical operation feasible

code show as below:

import matplotlib.pyplot as plt
import pandas as pd
import numpy as np

lines_df = pd.DataFrame(np.random.randn(1000,2),
                        columns = ['line_a','line_b']).cumsum()
lines_df.plot()

Encountered a situation today, when with pycharm, code can be executed normally, but matplotlib portrait has been no revealed,

Here Insert Picture Description

But the code in the anaconda executed, there is no question
this is the result of the implementation of spyder:

Here Insert Picture Description
Later found the problem, plus plt.show () can

plt.show()

Here Insert Picture Description

If you feel good, please send me a praise yo ~

Published 124 original articles · won praise 23 · views 20000 +

Guess you like

Origin blog.csdn.net/YmeBtc/article/details/104055057