N Alpha
N Alpha

Reputation: 43

how to install geoplot on google colab

How can we install geoplot in google colab?

!pip install geoplot

The above gives

Collecting geoplot
  Using cached https://files.pythonhosted.org/packages/e1/8f/46133752e1f02e70501939e739b81cbc85c79d7398c963b8a25a3178bffe/geoplot-0.4.1-py3-none-any.whl
Requirement already satisfied: mapclassify>=2.1 in /usr/local/lib/python3.6/dist-packages (from geoplot) (2.4.2)

But when I try to import geoplot the package is unrecognised

Upvotes: 0

Views: 1715

Answers (2)

korakot
korakot

Reputation: 40858

Cartopy is required for geoplot. You need to use apt to install it. Then, you can install geoplot with pip normally.

!apt install python3-cartopy
!pip install geoplot

Here's an example colab notebook

Upvotes: 1

DataCrusade1999
DataCrusade1999

Reputation: 2090

I think they don't recommend using pip install geoplot here is a link to their documentation hope it helps you can use conda though.

Upvotes: 1

Related Questions