1

Following the instructions in this page,I downloaded the basemap and its dependencies. When I run

sudo apt-get install python-mpltoolkits.basemap

It gives me the following output:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
python-mpltoolkits.basemap is already the newest version (1.0.7+dfsg-3build2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

the same thing for

sudo apt-get install python-matplotlib

But running the simpletest.py in the examples folder, gives me the following error:

    Traceback (most recent call last):
  File "simpletest.py", line 1, in <module>
    from mpl_toolkits.basemap import Basemap
ImportError: No module named basemap

I also tried the other method described the same page for installing from the source but the output is the same.I am running on ubuntu16.04 LTS. Any idea!

leena rose
  • 21
  • 4
  • the answer presented [here](http://stackoverflow.com/questions/29333431/importerror-when-importing-basemap) works for me – Alf Mar 27 '17 at 16:02

1 Answers1

1

if you're using Anaconda, it has a package for basemap: conda install basemap

Yuchao Jiang
  • 3,522
  • 30
  • 23