A while back I found a method to join Axes in a nice way. Now that I revisit the plot-making for a report I find that I'm not satisfied...
The reason for this is the overlap between the labels at the tics
of my plot. Since I joined the axes, the last of the left and first of the right plot tics
will overlap, shown in the below example with random sin and cos plotted.
How can I circumvent this in a general way. Please note that I will be plotting a lot of figures like these in series, figuring out each of these tics
depending on the values of my data is not an option for me.
Thanks in advance!
My plot-file: JointAxes.gp
# Generic gnuPlot script for plotting multiple plots in a single figure
# Resetting all variables. Standard for all plots.
reset
# Setting (terminal) options.
set terminal pdfcairo color font ",8"
set output 'JointAxes.pdf'
# Option to plot multiple graphs in one picture, note the number of figs here is 4 (2 by 2).
set multiplot layout 2,2 rowsfirst
# Macro's needed to produce a figure with all plots 'touching'.
set macros
# Small plot labels
LABEL = "at graph 0.9,0.9"
# Axes adjustment
set format x "%.1f"
XAXE = 'set xlabel "Extent"; set xtics -2*pi,pi/3 # N.B. tics should be changed due to conjoined axes.
YAXE = 'set ylabel "Amplitude"; set ytics -1,0.25
NOX = "unset xtics;\
unset xlabel"
NOY = "unset ytics;\
unset ylabel"
# Locking the graphs at fixed points in the figure
# Margins for each row resp. column
TMARGIN = "set tmargin at screen 0.90; set bmargin at screen 0.55"
BMARGIN = "set tmargin at screen 0.55; set bmargin at screen 0.20"
LMARGIN = "set lmargin at screen 0.10; set rmargin at screen 0.50"
RMARGIN = "set lmargin at screen 0.50; set rmargin at screen 0.90"
# General plot markup
unset key
# Legend/key adjustment
# set key samplen 3 # length of legend colour-bar
# set key spacing 1 # spacing between samples
# Optional: Adjusting range
set yrange [-1:1]
set xrange [-pi:pi]
# Plotting the first of the 'sub'-plot
@YAXE; @NOX
@TMARGIN; @LMARGIN
set label 1 'a' @LABEL
plot sin(x)
# Plotting the second 'sub'-plot, i.e. a new plot command.
@NOX; @NOY
@TMARGIN; @RMARGIN
set label 1 'b' @LABEL
plot cos(x)
# Plotting 3rd
@YAXE; @XAXE
@BMARGIN; @LMARGIN
set label 1 'c' @LABEL
plot sin(x + 1.57)
#And Fourth
@NOY; @XAXE
@BMARGIN; @RMARGIN
set label 1 'd' @LABEL
plot cos(x + 1.57)
unset multiplot
set terminal wxt
set output
# OEF