I figured out a solution so I thought I'd post it. Its seems overly complicated for what should be a simple switch in the gnuplot program. This creates two strings, $F967E and $F9682 which are appended to the part of the plot statement that always has data. If the file is empty, then the string is null for that file and no attempt is made to plot it.
In the scripting section of the script I added this:
Code:
if [ `stat --print="%s" 967E.dat` -ne 0 ]
then
F967E=" ,\
'967E.dat' using 1:5 axes x1y1 title '967E Sample'\
with points pt 5 ps .2 lw 1 lc rgb \"purple\""
fi
if [ `stat --print="%s" 9682.dat` -ne 0 ]
then
F9682=" ,\
'9682.dat' using 1:5 axes x1y1 title '9682 Sample'\
with points pt 5 ps .2 lw 1 lc rgb \"black\""
fi
In the gnuplot section of the script I changed this:
Code:
plot './fll.dat' using 1:14 axes x1y2 title 'Integrator Err' with points \
pt 5 ps .3 lc rgb "green", \
'./fll.dat' using 1:5 axes x1y1 title 'DAC' with lines \
lw 1 lc rgb "blue", \
'./integ.dat' using 1:5 axes x1y1 title 'Integrator Updates' \
with points pt 5 ps .2 lw 1 lc rgb "red" $F967E $F9682