Profile Creation in psxy
I am trying to create three profiles in a single plot. Data being extracted along profiles using grdtrack from 3 different grid files and it contains x,y,z data.
I want to plot x,z and couldnt do it after many attempts ( z is depth values and ranges from 10.0 to 11.0).
Please have a look on my following script,
gmt grdtrack -Gtest15cm.nc -E558603/5932023/558652/5932066 -nb -sa -o0,2 > T15.txt
gmt grdtrack -Gtest50cm.nc -E558603/5932023/558652/5932066 -nb -sa -o0,2 > T50.txt
gmt grdtrack -Gtest1m.nc -E558603/5932023/558652/5932066 -nb -sa -o0,2 > T1.txt
R558603/558652/5932023/5932066 -JX6i/.75i T15.txt -Wthick,black,. -O -K -X-4i -Y-1.2i -Bx10+l"East(m)" --FONT_LABEL=8p -By.2 -BWSne --FONT_ANNOT=7p >>ps -O >>ps
gmt psxy -R -JX6i/.75i T50.txt -Wthick,red,. -O -K >>ps
gmt psxy -R -JX6i/.75i T1.txt -Wthick,blue,
RE: Profile Creation in psxy - Added by Paul over 1 year ago
If your z values range from 10 to 11 then your -R is way off. Run gmt info T15.txt and so on and see what the -R option should be for your data. These are no longer x,y points but distance vs z.
RE: Profile Creation in psxy - Added by Eranda over 1 year ago
Hi Paul ,
I tried with gmt info to get values for -R and it was <558603/558652> <10.2985172746/10.8897487577>
Then I tried with
gmt psxy -R558603/558652/10.2985172746/10.8897487577 -JX6i/.75i T15.txt -Wthick,black,. -X-4i -Y-1.2i -Bx5+l"East(m)" --FONT_LABEL=8p -By.2 -BWSne --FONT_ANNOT=7p -V -P -K >>ps
But still not possible to get a result and not giving any error as well in cmd.
Thanks in advance for your time !!!
RE: Profile Creation in psxy - Added by Ema 6 months ago
How did you finally solve this problem? I am experiencing similar challenge now.