I have (lon,lat) data that mark a high resolution coastline. It is a very irregular coastline (estuary) and so when I use matplotlib's fill or fill_between functions, it does not work as it is supposed to, as it also fills parts outside the coast, inside the estuary, as well. I cannot use cartopy or basemap since their "full" resolution is not enough for what I need...
I have read a bunch of other posts (e.g.):
shapefile and matplotlib: plot polygon collection of shapefile coordinates
https://gis.stackexchange.com/questions/131716/plot-shapefile-with-matplotlib
That had the same issue as I do, but they work with shapefile, so I am not sure how can I use it with my data.
For what I have read so far, I think the answer to my problem is to create a closed polygon using path where one side is the coastline (from the data I have), and the others can be straight lines outside of my boundaries...I have read the documentation for path and Patch but have not been able to make it work. How can I do this?
Here is what I get using:
plt.plot(lonc,latc,'.')
plt.fill(lonc,latc)
(I am sorry I cannot provide the actual data I am working with)...