今日の一言
2011/01/21(Fri) 朝だー [長年日記] 10:00現在晴 5℃
_ [gnuplot][Debian][FC][Linux][Ubuntu][Windows]gnuplotで標準偏差を書く
「x,y,標準偏差」というデータを用意し、
$ plot 'hoge.dat' using 1:2:3 with errorbars
とすればOK。
_ [gnuplot][Debian][FC][Linux][Ubuntu][Windows]gnuplotでカンマ区切りのファイルを読み込む
set datafile separator ","
とすればOK。
_ [gnuplot][Debian][FC][Linux][Ubuntu][Windows]gnuplotで複数のグラフを一つの図にまとめる
5個のグラフを縦に並べる場合。(epsに出力)
set terminal postscript eps noenhanced monochrome font 30 set xlabel "x" set ylabel "y" set xrange [ 0.0 : 0.25 ] set yrange [ -0.2 : 0.2 ] set ytics -0.2, 0.2, 0.2 set output "raw_graph.eps" set multiplot set lmargin 10 set bmargin 3 set rmargin 2 set tmargin 1 set size 1.0,0.2 set origin 0.0,0.8 plot "1.dat" title "1" w l set origin 0.0,0.6 plot "2.dat" title "2" w l set origin 0.0,0.4 plot "3.dat" title "3" w l set origin 0.0,0.2 plot "4.dat" title "4" w l set origin 0.0,0.0 plot "5.dat" title "5" w l set nomultiplot !eps2eps -r12000 raw_graph.eps graph.eps
あとは応用で。
_ [gnuplot][Debian][FC][Linux][Ubuntu][Windows]gnuplotでグラフの任意の位置に文字を書き込む
参考:http://t16web.lanl.gov/Kawano/gnuplot/label2.html
こんな感じで書く。
set label "(0,0) first" at first 0, first 0 set label "(0,0) graph" at graph 0, graph 0 set label "(0,0) screen" at screen 0, screen 0
ここで、"first", "second", "graph", "screen"は座標系。
それぞれ、グラフの左のY座標と下のX 座標、右のY2座標と上のX2座標、グラフ内部の相対的な位置、画面内の相対的な位置を表す.
[TrackBack URL: http://akihiro-i.net/~akihiro-i/diary/tb.rb/20110121]