Gnuplot - formatting the plot name (line above the letter)

I want to create a gnuplot containing a line above the letter in the chart title. The image shows such an attempt:

enter image description here

The code that creates it looks like this (I paste this line into the gnuplot window in Windows 7 ):

set terminal pdf enhanced
set output "C:/linMitSaett.pdf"
set grid ytics lt 0 lw 1 lc rgb "#D3D3D3"
set grid xtics lt 0 lw 1 lc rgb "#D3D3D3"
set yrange [0:800]
set xlabel "Zeiteinheit {/Symbol t}" 
set ylabel "#Individuen  p({/Symbol t})"
set label "p_0=2" textcolor rgb "red" at 4,300
set label "p_0=400" textcolor rgb "blue" at 1,425
set label "p_0=800" textcolor rgb "green" at 4,510
set label "{/Symbol l}_0=200 (Wachstumsrate)\n{/Symbol l}_1=0.5 (Bremsrate)" at 4,160
plot [0:10] 400+(2-400)*exp(-0.5*x) title "p_0 < ~p{.7-}", 400+(800-400)*exp(-0.5*x) title "p_0 > ~p{.7-}", 400+(400-400)*exp(-0.5*x) title "p_0 = ~p{.7-}"
set output "C:/deleteme.pdf"
reset

How can I move the lines vertically down so that they align with each p, and not with the bar above each p?

+4
source share
1 answer

If you add set encoding utf8to your file, you can simply use the superscript character (U + 203E) in the shortcuts. This eliminates the need to add an offset to the character:

plot [0:10] 400+(2-400)*exp(-0.5*x) title "p_0 < ~p‾", \
            400+(800-400)*exp(-0.5*x) title "p_0 > ~p‾", \
            400+(400-400)*exp(-0.5*x) title "p_0 = ~p‾"

overline, UTF-8:

plot [0:10] 400+(2-400)*exp(-0.5*x) title "p_0 < ~p\342\200\276", \
            400+(800-400)*exp(-0.5*x) title "p_0 > ~p\342\200\276", \
            400+(400-400)*exp(-0.5*x) title "p_0 = ~p\342\200\276"
+5

All Articles