How to make annotations oblique to some angle with GMT5.4

Hi there,

I tried to change the angle of annotations of axes especially x-axis with ‘gmt set MAP_ANNOT_MIN_ANGLE 30’, but failed. I tired that with GMT 6.0 as well, but nothing was changed. Could anybody tell me why this setting is not available and how can make it? Thanks.

Alex

Since presumably you read the docs:

MAP_ANNOT_MIN_ANGLE

If the angle between the map boundary and the annotation baseline is less than this minimum value (in degrees), the annotation is not plotted (this may occur for certain oblique projections). Give a value in the range [0,90] [default is 20].

Is there anything in this paragraph that suggest to you it has anything to do with adjusting annotation angles?

Look at axis settings under -B option and its +a modifier:

  • +a angle (for Cartesian plots only) to plot slanted annotations, where angle is measured with respect to the horizontal and must be in the -90 <= angle <= 90 range. +an can be used as a shorthand for normal (i.e., +a90) [Default for y-axis] and +apfor parallel (i.e., +a0) annotations [Default for x-axis]. These defaults can be changed via MAP_ANNOT_ORTHO.

However, very unlikely this existed in 5.4 - hence please update.

Thanks, I tried to set ‘MAP_ANNOT_MIN_ANGLE’ to 30, but it seemed not worked. I dont know why. Actually, I used ‘-Bpxcannotation.txt’ (annotation.txt file was edited by some station name) in the command line:
gmt psxy -R -J -Bpxcannotation.txt --'MAP_ANNOT_MIN_ANGLE=30 -O -K -P< $psfl
1 3
2 2
3 2
4 8
5 6
EOF
It didn’t work.

I don’t think you read my email. MAP_ANNOT_MIN_ANGLE Has nothing to do with your question.

I tried this option with GMT6.0 but failed again.

If you post annotations.txt and spell out what -R and -J are we could actually test it.

The annotation file is attached. The command line I used is:
gmt psbasemap -R0/5/0/10 -JX4i/4i -BWSEN -Bpya1f1g1 -Bpxa1f1g1+a30 -Bpxcannot.txt -K -P > test.psannot.txt (55 Bytes)

gmt psbasemap -R0/5/0/10 -JX4i/4i -BWSEN -Bpya1f1g1 -Bpxa1f1g1+a30 -Bpxcannot.txt -png lixo

Thanks. But what a shock! I tried your command line in my PC but failed (see the enclosed). My current version of GMT is ‘GMT - The Generic Mapping Tools, Version 6.0.0_r19277 [64-bit] [1 cores] (c) 1991-2017 Paul Wessel, Walter H. F. Smith, Remko Scharroo, Joaquim Luis, and Florian Wobbe’. What’s the reason for that?

Not because we haven’t told you many times to update your GMT.

By my calendar, 2017 was 5-6 years ago. What are you thinking?