Fornax-A
Fornax-A

Reputation: 1032

GNUPLOT how to add more space to indexes in labels

I try to put the space to the index in the letters of the labels of Gnuplot. I use the following command:

    set terminal pngcairo size 500,400 enhanced font 'Verdana,10'
    set output 'test.png'
    set xlabel 'atan(~{/Symbol w}{.6\~}_2)'
    set ylabel 'atan(~{/Symbol w}{.6\~}_2)'
    plot sin(x)

As you can see from the plot here the _2 over-plot the symbol. Could someone help me to understand how to put extra space to the indexes?

plot

Upvotes: 2

Views: 886

Answers (1)

Tom Fenech
Tom Fenech

Reputation: 74705

Admittedly, this is a bit of a hacky solution but it seems to work:

set xlabel 'atan(~{/Symbol w}{.6\~} _2)'
set ylabel 'atan(~{/Symbol w}{.6\~} _2)'

Adding the space after the symbol means that the subscript 2 doesn't overlap with it:

graph with no overlap

Upvotes: 2

Related Questions