Hello! We are trying to add the coastline to a grid in South America.
However, it does not draw the right coastline, and we cannot understand why.
It should be South America to the east and Pacific Ocean to the west, But it displays some islands…
This is our line of command:
gmt begin map pdf, ps
gmt coast -JT-77/-11/10c -R-91/-65/-17/-5 -I1blue -Cgray
gmt end show
The islands are probably here for real.
Coast has an option to draw only object spanning enough surface, so if you want to get rid of the tiny chunks of dirt, you can use that (see -A)
You are writing you want to add shorelines to your plot, but currently the code example you posted does not contain -W to add shorelines to your map. -I adds rivers and -C fills the lakes by a color.
If I expand your code:
# I rivers - here drawn in cyan with 1 point thickess
# W shorelines - here drawn in blue with 1 point thickess
# G land - here filled in lightgray
# C lakes - here filled in darkgray
gmt begin map_shorelines png
gmt coast -JT-77/-11/10c -R-91/-65/-17/-5 -I1/1p,cyan -W1/1p,blue -Ggray80 -Cgray30 -Bafg
gmt end