I'm having a bit of trouble plotting polygon/multipolygon data with Geoviews. I have made a geodataframe that combines my two datasets together nicely. I am able to plot the data easily using the plot function:
See below:
import geopandas as gpd
import numpy as np
import pandas as pd
import holoviews as hv
import geoviews as gv
import geoviews.feature as gf
import cartopy
import cartopy.feature as cf
from geoviews import opts
from cartopy import crs as ccrs
gv.extension('bokeh')
Drop_na.plot(column = 'Registrations',figsize=(10,10), legend=True)
This gives me the below chart:
However, when I try to plot the same using GeoViews with the code below:
gv.Polygons(Drop_na, vdims=['Registrations']).opts(
tools=['hover'], width=550, height=700, color_index='Registrations',
colorbar=True, toolbar='above', xaxis=None, yaxis=None, padding=0.1)
I get the following error: "While projecting a Polygons element from a PlateCarree coordinate reference system (crs) to a PlateCarree projection none of the projected paths were contained within the bounds specified by the projection. Ensure you have specified the correct coordinate system for your data."
I've read around the documentation and have tried different ways of messing around with the projection method but i just can't get it generate the same chart or any chart for that matter.
Does anyone know what i'm doing wrong?
Kind regards, Amen