MKL Gnuplot useful stuff & notes



More details on gnuplot:
Enhanced postscript
Gnuplot - not so Frequently Asked Questions
Point, line types etc.
Multiplot, insets etc.
... and Google.

Sample Gnuplot preamble
set term post eps enh mono 20 "Times-Roman" dashed dl 4
set border linewidth 1.5
set xlabel '(qL)^2'
set ylabel '{/Symbol G}^{rr}/D@^r_{/Symbol \136}'
set key below
set out '../Beads_RR_vs_q2.eps'
set title 'Bead model results with full hydrodynamics: RR'
plot \
'Rod_full_hydro_kL_0.0_N_5.dat' every 2::0 u 1:11 w p pt 7 lw 3 lc rgb 'brown' ti '{/Symbol k}L=0', \
'BULK/Bead_Rod_Bulk_cumulant_N_5.dat' u 1:4 w l lt 1 lw 5 ti 'Bulk', \
'Rod_full_hydro_kL_1.0_N_5.dat' every 2::0 u 1:11 w l lt 2 lw 5 ti '{/Symbol k}L=1', \
'Rod_full_hydro_kL_2.5_N_5.dat' every 2::0 u 1:11 w l lt 3 lw 5 ti '{/Symbol k}L=2.5' set out
unset title
set key inside
set key t l
# every 2::0 plots every second data line ; differently for plotting selected BLOCKS, not lines.


EPSLATEX format

#inFileName = "out/response_new.dat"
outFileName = "response_new.tex"

set terminal epslatex size 4.5,3.0 standalone rounded dashlen 4 color colortext 12
set encoding utf8

set output(outFileName)
set grid lw 1 lc rgb "#7F7F7F";
set key samplen 3.5
set key top right font ",3" Left width 1
#set format x '$10^{%T}$';
#set format y '$10^{%T}$';
#unset key;
#unset border;
#unset xtics;
#unset ytics;
set xrange [0:1.2]
set yrange [0:1.1]

#set xtics(-15,"$w_p$" -11.5,"" -10,"$w_r$" -6.2,-5,"" 0,"$w_q$" 0.2,5)
#set xtics (1e-2,"" 1e-1,1,"" 1e1,100,"" 1e3,1e4,"" 1e5,1e6) font ",8"
set mxtics
#set ytics (0,"" 0.01,0.02,"" 0.03,0.04,"" 0.05,0.06) font ",8"
set mytics
set xlabel '$\ln t/\tau_0$'
set ylabel "$\\tilde{K}_{100}$"offset 1,0
colors = "black #00008B #006400 #8B0000 #FF4500 #800080 #9ACD32"

#set arrow from 0.2,graph(0,0) to 0.2,graph(1,1) lt 4 lw 3 lc rgb "black" nohead
#set label "$\\scriptstyle D=1.0005D_{min}$" at 0.15,0.053

plot sin(x) w l lw 4 lt 1 lc rgb word(colors,1) title '$H=2.5 R$' \
,sin(2*x) w l lw 4 lt 2 lc rgb word(colors,2) title '$H=10R$' \
,sin(3*x) w l lw 4 lt 3 lc rgb word(colors,3) title '$H=100R$' \
,sin(4*x) w l lw 4 lt 4 lc rgb word(colors,4) title '$H=1000R$'

set output

Tex -> eps script

#!/bin/bash
fileName=$1
latex $fileName".tex"
dvips $fileName".dvi" -o $fileName".eps"
mv $fileName".eps" "_out.eps"
rm *.dvi *.aux *.log