AttributeError: 'function' object has no attribute 'add_subplot' when using matplotlib in ipython -


hi, trying code wesmckinney's python data analysis book in ipython environment,which built in anaconda. when typed simple code

import matplotlib.pyplot plt  fig = plt.figure  ax1 = fig.add_subplot(2,2,1) traceback (most recent call last):  file "<ipython-input-9-559e30a6412a>", line 1, in <module> ax1 = fig.add_subplot(2,2,1)  attributeerror: 'function' object has no attribute 'add_subplot' 

an attributeerror arose, it's weird since anaconda surely installed matplotlib module. suggestion? thank you.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -