Difference between revisions of "Gnuplot"
From orch
(→First script) |
(→First script) |
||
Line 27: | Line 27: | ||
<code> | <code> | ||
set xrange [0:3*pi] | set xrange [0:3*pi] | ||
− | set | + | set yrange [-1:1] |
</code> | </code> | ||
Revision as of 14:05, 11 March 2016
First script
set terminal postscript eps enhanced color "Times-Roman" 20
set style line 1 linetype 1 linecolor rgb "696969" linewidth 3.0 pointtype 1 set style line 2 linetype 1 linecolor rob "FF6600" linewidth 3.0 pointtype 1
set output "graph.eps"
a = 0.8 f(x) = a * cos(x) g(x) = a * sin(x)
pi = 3.14159265359
set xrange [0:3*pi] set yrange [-1:1]
set xlabel "x coordinate" unset ylabel
plot f(x) with points title 'sin(x)' ls 1,\ g(x) with points notitle ls 2
Macros
T_GRAPH = "set tmargin at screen 0.99; set bmargin at screen 0.81" B_GRAPH = "set tmargin at screen 0.74; set bmargin at screen 0.56"
L_GRAPH = "set lmargin at screen 0.12; set rmargin at screen 0.45" R_GRAPH = "set lmargin at screen 0.61; set rmargin at screen 0.94"