I am trying to do a multiplot. Following are the 4 files that I used with
File1.csv
,col1,col2,col3,col4,col5,col6
10,-39, 0.7, 0, 0,99.3, 0
14,-42, 0.0, 0, 0, 100, 0
42,-64, 0, 0, 0, 100, 0
46,-67, 2.5, 0, 0,97.5, 0
50,-69, 7.6, 0, 0,92.4, 0
54,-75, 0, 0, 0, 100, 0
58,-78, 3.7, 0, 0,96.3, 0
62,-82, 69.0, 0, 0,31.0, 0
66,-85, 0, 0, 0, 0, 0
70,-100,0,0,0,0,0
74,-100,0,0,0,0,0
70,-100,0,0,0,0,0
66,-100,0,0,0,0,0
62,-100,0,0,0,0,0
58,-78, 2.1, 0, 0,97.9, 0
54,-74, 2.9, 0, 0,97.1, 0
50,-69, 2.3, 0, 0,97.7, 0
46,-65, 2.4, 0, 0,97.6, 0
42,-65, 0, 0, 0, 100, 0
14,-43, 1.5, 0, 0,98.5, 0
10,-40, 1.0, 0, 0,99.0, 0
File2.csv
,col1,col2,col3,col4,col5,col6
10,-39, 0.7, 0, 0,99.3, 0
14,-42, 0.0, 0, 0, 100, 0
42,-64, 0, 0, 0, 100, 0
46,-67, 2.5, 0, 0,97.5, 0
50,-69, 7.6, 0, 0,92.4, 0
54,-75, 0, 0, 0, 100, 0
58,-78, 3.7, 0, 0,96.3, 0
62,-82, 69.0, 0, 0,31.0, 0
66,-85, 0, 0, 0, 0, 0
70,-100,0,0,0,0,0
74,-100,0,0,0,0,0
70,-100,0,0,0,0,0
66,-100,0,0,0,0,0
62,-100,0,0,0,0,0
58,-78, 2.1, 0, 0,97.9, 0
54,-74, 2.9, 0, 0,97.1, 0
50,-69, 2.3, 0, 0,97.7, 0
46,-65, 2.4, 0, 0,97.6, 0
42,-65, 0, 0, 0, 100, 0
14,-43, 1.5, 0, 0,98.5, 0
10,-40, 1.0, 0, 0,99.0, 0
File3.csv
,col1,col2,col3,col4,col5,col6
10,-39, 0.7, 0, 0,99.3, 0
14,-42, 0.0, 0, 0, 100, 0
42,-64, 0, 0, 0, 100, 0
46,-67, 2.5, 0, 0,97.5, 0
50,-69, 7.6, 0, 0,92.4, 0
54,-75, 0, 0, 0, 100, 0
58,-78, 3.7, 0, 0,96.3, 0
62,-82, 69.0, 0, 0,31.0, 0
66,-85, 0, 0, 0, 0, 0
70,-100,0,0,0,0,0
74,-100,0,0,0,0,0
70,-100,0,0,0,0,0
66,-100,0,0,0,0,0
62,-100,0,0,0,0,0
58,-78, 2.1, 0, 0,97.9, 0
54,-74, 2.9, 0, 0,97.1, 0
50,-69, 2.3, 0, 0,97.7, 0
46,-65, 2.4, 0, 0,97.6, 0
42,-65, 0, 0, 0, 100, 0
14,-43, 1.5, 0, 0,98.5, 0
10,-40, 1.0, 0, 0,99.0, 0
File4.csv
,col1,col2,col3,col4,col5,col6
10,-39, 0.7, 0, 0,99.3, 0
14,-42, 0.0, 0, 0, 100, 0
42,-64, 0, 0, 0, 100, 0
46,-67, 2.5, 0, 0,97.5, 0
50,-69, 7.6, 0, 0,92.4, 0
54,-75, 0, 0, 0, 100, 0
58,-78, 3.7, 0, 0,96.3, 0
62,-82, 69.0, 0, 0,31.0, 0
66,-85, 0, 0, 0, 0, 0
70,-100,0,0,0,0,0
74,-100,0,0,0,0,0
70,-100,0,0,0,0,0
66,-100,0,0,0,0,0
62,-100,0,0,0,0,0
58,-78, 2.1, 0, 0,97.9, 0
54,-74, 2.9, 0, 0,97.1, 0
50,-69, 2.3, 0, 0,97.7, 0
46,-65, 2.4, 0, 0,97.6, 0
42,-65, 0, 0, 0, 100, 0
14,-43, 1.5, 0, 0,98.5, 0
10,-40, 1.0, 0, 0,99.0, 0
Gnuplot script I got is histogram graph on x1y1 axis and linespoint graph on x2y1 axis
set colors classic
set terminal png notransparent size 1800,640 truecolor medium
set output 'reading.png'
set grid front
set tmargin -1; set bmargin -1
set lmargin -1; set rmargin -1
set style data histogram
set style histogram rowstacked
set style fill solid
set boxwidth 0.5
set datafile separator ","
set xtics axis
set yrange [0:100]
set y2range [-100:-10]
set y2tics
set y2label "Y2Label"
set ylabel "YLabel"
set multiplot layout 4,1
unset xtics
unset key
plot for [COL=3:6] 'file1.csv' u COL:xtic(1) axes x1y1 ti col,'' u 2:xtic(1) with linespoint axes x1y2
plot for [COL=3:6] 'file2.csv' u COL:xtic(1) axes x1y1 ti col,'' u 2:xtic(1) with linespoint axes x1y2
plot for [COL=3:6] 'file3.csv' u COL:xtic(1) axes x1y1 ti col,'' u 2:xtic(1) with linespoint axes x1y2
set key below
set xtics
plot for [COL=3:6] 'file4.csv' u COL:xtic(1) ti col,'' u 2:xtic(1) with linespoint axes x1y2
unset multiplot
The resultant graph that I got is having different starting points on x-axis. Can someone please help synchronize histogram and linespoint plots in this.
set link x2
, but if you want x2 to be the same as x1 why not just use x1?