Last active
October 31, 2020 07:37
-
-
Save shreyagupta30/fc35858b1347c23eb68ecca5308f5897 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import matplotlib.pyplot as plt | |
import cartopy.crs as ccrs | |
import cartopy.feature as cfeature | |
from cartopy.io.shapereader import Reader | |
from cartopy.feature import ShapelyFeature | |
fig = plt.figure(figsize=(9,11)) | |
ax = plt.axes(projection=ccrs.PlateCarree()) | |
ax.set_extent([68.04999,97.95001, 5.5, 37.45], ccrs.PlateCarree()) | |
#Overlaying of administrative boundries | |
filename = r'./India-States.shp' | |
shape_feature = ShapelyFeature(Reader(filename).geometries(),ccrs.PlateCarree(), | |
linewidth = 1, facecolor = 'none', | |
edgecolor = 'black') | |
ax.add_feature(shape_feature) | |
ax.add_feature(cfeature.OCEAN) | |
ax.add_feature(cfeature.LAND,edgecolor='black') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment