5 my $dataFile = $ARGV[0];
6 my $yrange = $ARGV[1] || 30;
7 my $ytics = $ARGV[2] || 5;
8 my $y2range = $ARGV[3] || 60;
9 my $y2tics = $ARGV[4] || 10;
11 my $title = "Sequencing depth distribution";
12 my $font = 'font "Arial-Bold,24"';
13 my $titleFont = 'font "Arial-Bold,32"';
20 my $script = << "script";
21 set terminal postscript eps enhanced defaultplex leveldefault color colortext dashed dashlength
3.0 linewidth
1.0 butt palfuncparam
2000,0.003 "Helvetica" 16
23 #set title '$title' $titleFont
26 set yrange
[0:$yrange]
27 set y2range
[0:$y2range]
29 set ytics
$ytics $font
30 set y2tics
$y2tics $font
34 set boxwidth
0.8 absolute
35 #set style fill solid 1.00 border 0
36 set style histogram clustered gap
1 title offset character
0, 0, 0
37 set datafile missing
'-'
38 set style data histograms
39 set xtics border
in scale
1,0.5 nomirror rotate by
-60 offset character
-1, -0.5, 10
40 #set xtics border in scale 1,0.5 nomirror offset character 0, -0.5, 10
42 set style line
1 linetype
1 linecolor rgb
"navy" linewidth
5.000 pointtype
5 pointsize
$pointSize
43 set style line
2 linetype
1 linecolor rgb
"green" linewidth
5.000 pointtype
7 pointsize
$pointSize
44 set style line
3 linetype
1 linecolor rgb
"pink" linewidth
5.000 pointtype
11 pointsize
$pointSize
46 #set style histogram rowstacked
49 set key horizontal Left
reverse enhanced autotitles columnhead nobox spacing
2.5 width
5.4 top left
50 #set key outside right spacing 1.2
51 set size
$xScale,$yScale
54 set output
"$dataFile.eps"
55 set xlabe
"\\n\\nChromosome\\n\\n" $font
56 set ylabe
"Sequencing depth(X)\\n" $font
57 set y2labe
"\\nGC(\%)\\n" $font
59 plot
'$dataFile' using
4:xtic
(1) title
"{/Arial=$legendSize Mode depth}" fs pattern
0 ls
1,'' u
3 title
"{/Arial=$legendSize Mean Depth}" with linespoints ls
2, '' using
5:xtic
(1) title
"{/Arial=$legendSize GC(\%)}" with linespoints axes x1y2 ls
3