1
votes

I try to make a figure using multiplot, but some axes are weird (see figure). I use epslatex to generate a standalone tex file. It looks like a "box" limits the axis, but I cannot figure out what the corresponding option is.

The code used to generate the figure is below.

reset

set term epslatex color standalone header \
    "\\usepackage[utf8]{inputenc}\n\\usepackage[T1]{fontenc}\n\\usepackage{cmbright}\n"

set output 'correlations.tex' 

set pm3d at b
set pm3d map
unset surface
set pm3d corners2color c4

eps = 1.e-6
f(x)=(log(abs(x)/eps+1))*sgn(x)
set palette functions 2*(gray), 1-2*abs((gray)-.5), 2-2*(gray)
zmax = 1
set cbrange [f(-zmax):f(zmax)]

SX=0.8; SY=0.8
set bmargin 0; set tmargin 0; set lmargin 0; set rmargin 0
X0=0.1; Y0=0.1
DX=0.46; DY=0.64

set size X0+SX+DX,Y0+SY+DY
set origin 0,0

#
# Multiplot
#

set multiplot

#
# bottom left
#

set origin X0,Y0

unset colorbox
unset key

set size square SX,SY

xmax = 5
xshift = 0

set xrange [-xmax-xshift:xmax-xshift]
set yrange [-xmax:xmax]

set xlabel '$x_\parallel$'
set ylabel '$x_\perp$'

set xtics -5,5,5
set ytics -5,5,5

datafile = '../Résultats/correl_pm_smooth2f1.0cutoff5.0xMax5.0nX61.dat'

splot datafile u 1:2:(f($3)) w l t '',\
    datafile u 1:(-$2):(f($3)) w l t ''

#
# top left
#

set origin X0,Y0+DY

set xlabel ''
set ylabel ''

set xtics ("" -5, "" 0., "" 5)

datafile = '../Résultats/correl_pm_smooth2f0.0cutoff5.0xMax5.0nX61.dat'

splot datafile u 1:2:(f($3)) w l t '',\
    datafile u 1:(-$2):(f($3)) w l t ''

#
# top right
#

set origin X0+DX,Y0+DY

set xtics ("" -5, "" 0., "" 5)
set ytics ("" -5, "" 0., "" 5)

datafile = '../Résultats/correl_pm_smooth2f0.5cutoff5.0xMax5.0nX61.dat'

splot datafile u 1:2:(f($3)) w l t '',\
    datafile u 1:(-$2):(f($3)) w l t ''

set origin X0+DX,Y0
set colorbox
set xtics -5,5,5

datafile = '../Résultats/correl_pm_smooth2f5.0cutoff5.0xMax5.0nX61.dat'

splot datafile u 1:2:(f($3)) w l t '',\
    datafile u 1:(-$2):(f($3)) w l t ''

unset multiplot
1

1 Answers

0
votes

I found the answer. With the epslatex terminal, the size and position of the various items refer to the size of the canvas and should thus be contained in the 1x1 box.

Changing the size of the terminal is done via "set term epslatex size 5,5…".