|
From: babelproofreader <bab...@gm...> - 2013-03-03 15:01:34
|
I have a script file ( part shown below ) which used to work with problem but
is now failing on line 36 with
"all_plots", line 36: invalid expression
if ($5 == 1) plot "<head -$3 $1ind | tail -$2" using 1:253:254:255:256
notitle with candlesticks linecolor rgb "#5C5C5C", \
"<head -$3 $1ind | tail -$2" using 1:101 title 'Sinewave' with
line lw 1 linecolor rgb "#FFFF00", \
"<head -$3 $1ind | tail -$2" using 1:($$102>0.75?$$102:1/0)
title 'Leadsine1' with line lw 1 linecolor rgb "#EE00EE", \
"<head -$3 $1ind | tail -$2" using 1:($$102<-0.75?$$102:1/0) notitle
with line lw 1 linecolor rgb "#EE00EE", \
"<head -$3 $1ind | tail -$2" using 1:($$103>0.75?$$103:1/0)
title 'Leadsine2' with line lw 1 linecolor rgb "#DC143C", \
"<head -$3 $1ind | tail -$2" using 1:($$103<-0.75?$$103:1/0) notitle
with line lw 1 linecolor rgb "#DC143C", \
"<head -$3 $1ind | tail -$2" using 1:104 title 'Sinewave_tp'
with line lw 1 linecolor rgb "#00FFFF", \
"<head -$3 $1ind | tail -$2" using 1:($$105>0.75?$$105:1/0)
title 'Leadsine1_tp' with line lw 1 linecolor rgb "#EE00EE", \
"<head -$3 $1ind | tail -$2" using 1:($$105<-0.75?$$105:1/0) notitle
with line lw 1 linecolor rgb "#EE00EE", \
"<head -$3 $1ind | tail -$2" using 1:($$106>0.75?$$106:1/0)
title 'Leadsine2_tp' with line lw 1 linecolor rgb "#DC143C", \
"<head -$3 $1ind | tail -$2" using 1:($$106<-0.75?$$106:1/0) notitle with
line lw 1 linecolor rgb "#DC143C", \
Zeroline(x) notitle with line lt 0 lw 1 linecolor rgb "#00FFFF"; else
where this last line is line 36. Suspecting that the new block structured
if/else statements might be the cause ( I am now using Gnuplot 4.6.0 on
Linux MInt Debian 64 bit, with Gunplot installed via the package manager ) I
tried using the new curly brackets thus
if ($5 == 1) { plot "<head -$3 $1ind | tail -$2" using 1:253:254:255:256
notitle with candlesticks linecolor rgb "#5C5C5C", \
..........................................
Zeroline(x) notitle with line lt 0 lw 1 linecolor rgb "#00FFFF"; } else {
but I'm still getting the line 36 error message. Any suggestions as to what
I need to change?
--
View this message in context: http://gnuplot.10905.n7.nabble.com/New-if-else-syntax-has-broken-my-scripts-tp17140.html
Sent from the Gnuplot - User mailing list archive at Nabble.com.
|