1# 2# Illustrate custom placement of individual plot titles outside the key box 3# 4set style data boxes 5set style fill solid border 6set boxwidth 0.5 7set datafile missing '-' 8set yrange [0:*] 9unset ytics 10unset xtics 11set xrange [-0.5:7.5] 12set offset 0,0,graph .1,0 13 14set label 1 at screen 0.75, screen 0.22 "{/:Bold Custom combined key area}" center 15set key autotitle columnhead nobox title " " 16set multiplot layout 3,2 columnsfirst \ 17 title "{/:Bold Illustrate use of a custom key area}" \ 18 margins 0.05, 0.95, 0.05, 0.90 spacing 0.0, 0.0 19 20plot 'immigration.dat' using 0:6 lt 1 title at 0.75, 0.18 21plot 'immigration.dat' using 0:12 lt 2 title at 0.75, 0.15 22plot 'immigration.dat' using 0:13 lt 3 title at 0.75, 0.12 23plot 'immigration.dat' using 0:14 lt 4 title at 0.75, 0.09 24set xtics scale 0 font ",8" 25 26plot 'immigration.dat' using 0:($6+$12+$13+$14):xtic(strcol(1)[6:]) with linespoints \ 27 lt black pt 7 title "total" 28 29unset multi 30 31if (exists("MANUAL_FIGURES")) exit 32pause -1 "Hit return to continue" 33 34reset 35# 36# Use of `keyentry` to construct a key 37# ==================================== 38# 39reset 40set title "{/:Bold Construct key from custom entries}" 41set tics scale 0 42unset xtics 43set xrange [-0.5:4.5] 44set x2range [-0.5:4.5] 45set yrange [3.5:-0.5] 46set x2tics ("A" 0, "B" 1, "C" 2, "D" 3, "E" 4) 47set ytics 0,1 48set palette rgbform -7,2,-7 49unset colorbox 50set style fill solid border lc "black" 51set key outside right center reverse Left samplen 1 52set key title "{/:Bold Outcomes}" left 53 54$HEATMAP << EOD 555 4 3 1 0 562 2 0 0 1 570 0 0 1 0 580 1 4 1 3 59EOD 60 61plot $HEATMAP matrix with image pixels notitle, \ 62 keyentry with boxes fc palette cb 0 title "no effect", \ 63 keyentry with boxes fc palette cb 1 title "threshold", \ 64 keyentry with boxes fc palette cb 3 title "typical range", \ 65 keyentry with labels title "as reported in [12]", \ 66 keyentry with boxes fc palette cb 5 title "strong effect" 67 68pause -1 "Hit return to continue" 69 70reset 71