ValueError: 'box_aspect' and 'fig_aspect' must be positive

Viewed 457

I'm trying to load and display my area of interest from a GEOJSON file . My code is bellow

country = gpd.read_file(os.path.join('C:/area.geojson'))
country_shape = country.geometry.values[-1]
country.plot()
plt.axis('off');

I get this error

ValueError: 'box_aspect' and 'fig_aspect' must be positive

Any help please !

1 Answers

I had a similar issue and found the answer here. Try:

country.plot(aspect=1)

Related