1
在gnuplot的4.6.p3,當我把一個腳本,據法權產,我應該從文件中繪製的列,通過gnuplot的宏美元符號替代
call 'FitModes.gnp' 12 "0.95" 1 "-50"
與(的麻煩部分)「FitModes.gnp」是:
c(x)= x==1?'using 3:(abs($$5)):6': x==2?'using 3:(abs($$7)):8': x==3?'using 3:(abs($$9)):10':0
column = c($2)
#print to check the value of this variable
print "column=",column
p "th$0/b$1/m$3/Data_$0-$1-$3.txt" @column t 'Data' w yerrorlines pt 7 lc @cblue
這使我 「無效表達」 輸出:
gnuplot> call 'FitModes.gnp' "12" 0.95 1 "-50"
column=using 3:(abs($5)):6
gnuplot> p "th12/b0.95/m-50/Data_12-0.95--50.txt" using 3:(abs()):6 t 'Data' w yerrorlines pt 7 lc rgbcolor "#0083AB"
由於不存在柱NU的儘管在column
變量中存在$5
,但仍可以使用abs()
函數。任何想法爲什麼?
非常感謝!奇蹟般有效。 – Jep 2014-10-22 17:00:03