我的X和Y标签被切断PICgnuplot的 - 标签切断情节
我发现作物/ nocrop选项,但没有奏效。 如何设置保证金?正如你所看到的,这些数据涵盖了标题(右上角)。我怎样才能在那里设置保证金?
以下代码来自我的bash脚本。
#set output
set terminal png large size 1920,1080 enhance background rgb '$BKGD_COLOR'
set output '$PLOT_OUTPUT_DIR/BW_${ArrayFile[$j]}_$DATE.png'
#set data
set datafile separator ","
set timefmt '%d/%m/%Y %H:%M:%S'
set xdata time
set format x "%d/%m/%Y\n%H:%M:%S"
#set axis (new style named 11, disable top and right axis, disable tics on top and right)
set style line 11 linecolor rgb '$TEXT_COLOR' linetype 1
set border 3 back linestyle 11
set tics nomirror font "/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf,16" textcolor rgb "$TEXT_COLOR"
#set grid
set style line 12 linecolor rgb '$TEXT_COLOR' linetype 0 linewidth 1
set grid back ls 12
#set line style
set style line 1 lc rgb '$RCVD_COLOR' pt 1 ps 1 lt 1 lw 2
set style line 2 lc rgb '$SENT_COLOR' pt 6 ps 1 lt 1 lw 2
#set text
set key font "/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf,10" textcolor rgb "$TEXT_COLOR"
set title 'Bandwidth (Mbps)' font "/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf,14" textcolor rgb '$TEXT_COLOR'
#Removed - set ylabel 'Mbps' textcolor rgb '$TEXT_COLOR'
set yrange [0:*]
#plot using the column 1 and 3 of the CSV file. with line points and title 'Bytes Received' and line style 1 (as defined above)
plot '$DIR/ResultsCSV/mg_bandwidth/${ArrayFile[$j]}.csv' u 1:3 w lp ls 1 t 'Bytes Received', '$DIR/ResultsCSV/mg_bandwidth/${ArrayFile[$j]}.csv' u 1:4 w lp ls 2 t 'Bytes Sent'
很酷。但是,你知道我是否可以删除钥匙中的红色和绿色线,只保留一个小彩点? –
@CharlyRoch关键将会匹配情节的风格。因此,当你使用线点时,键也会使用它。你可以使用直线绘制相同的数据两次,然后再次使用点,抑制第一个绘图上的按键,如'plot datafile w lines notitle,datafile w points title'示例'lt 1'使得只有按键出现点。您只需指定线条类型以确保它们使用相同的线条类型。情节看起来与现在一样,但你只会得到关键点。 – Matthew
非常聪明!但是并没有减少传说与观点之间的距离。我的意思是像“legend_____dot”这样的大空格。谢谢 –