gmt begin plot png
gmt basemap -JM10i -R-10/62/11/53 -Ba4f2
gmt coast -S101/148/188 -EFR,EG,KW,DZ+g244/164/96 -A2000
gmt plot -Sa0.5c -W1 -Gred << EOF
02:21:05 48:51:25
003.0331 036.4635
31:14:09 30:02:40
47:36:00 29:10:00
EOF
Are you using bash or batch files? I suspect that in the later you can’t do << EOF (it doesn’t exist).
I hardly recomend you to use bash files.
Heartedly recommend bash
yes I use batch. thank you
As you said, you are using Windows OS, then EOF will not work there. Please try
echo.
ChatGPT always give this EOF thing (In case you are also trying to use it). I personally feel, ChatGPT isn’t reliable for GMT scripts. It give biased results.
You should copy the content of the EOF into a .txt file. For instance, if the file is named as VVV.txt, then the next line becomes
gmt plot -Sa0.5c -W1 -Gred VVV.txt
this is what I really do, but I need to plot just two or three points so I need to input them into the batch file.
I am not asking chatgpt, I use .txt files to plot data points but I ask if I can input two or three points in the batch file directly, I think echo is used for a single point?
You would have to do tedious things like this;
echo first point > tmpfile
echo second point >> tmpfile
echo third point >> tmpfile
And then plot tmpfile.