2017-01-19 6 views
0

棒グラフとyerrorlinesに関する質問があります。どのように一緒にプロットすることができますか?私はそれを取得できませんよ、棒グラフとyerrorlinesを1つのプロットにまとめます

enter image description here

しかし:私はこのようなグラフをプロットしたいです。

x Scheme#1 Scheme#2 Scheme#3 Minfor#1 Mxfor#1 Minfor#2 Mxfor#2 Minfor#3 Mxfor#1 
20 0.0351 0.04562 0.04777 0.0208 0.0385 0.0415 0.0526 0.0397 0.05601 
40 0.03279 0.03946 0.034171 0.0266 0.0393 0.0323 0.04662 0.0278 0.04055 
60 0.03367 0.033792 0.037776 0.0272 0.0401 0.02692 0.04066 0.029 0.04584 

プロット機能

plot "data.file" using 2:xticlabels(1) title 'Scheme 1', \ 
    "data.file" using 3 title ' Scheme 2', \ 
    "data.file" using 4 title ' Scheme 3',\ 
    "data.file" using 0:2:5:6 title 'Confidence Interval for Scheme 1' with yerrorlines,\ 
    "data.file" using 0:3:7:8 title 'Confidence Interval for Scheme 2' with yerrorlines,\ 
    "data.file" using 0:4:9:10 title 'Confidence Interval for Scheme 3' with yerrorlines 

カラム5及び6 COL内のデータの信頼区間の値を含ん2 カラム7及び8は用信頼区間の値を含んでい列3のデータ 列9および列10には、列4のデータに対する信頼区間の値が含まれます。

答えて

0

あなたはこのような何かを試すことができます。

set terminal pngcairo 
set output "witherrorbars.png" 

set yrange [0:] 

set bars 2 

set style data histogram 
set style histogram errorbars gap 1 lw 1 
set style fill solid border -1 

plot "data.file" using 2:5:6:xtic(1) title 'Scheme 1' lc 5, \ 
    "data.file" using 3:7:8   title 'Scheme 2' lc 7, \ 
    "data.file" using 4:9:10  title 'Scheme 3' lc 9 

興味深い行はボックスやエラーバーを組み合わせたset style histogram errorbarsです。

boxes with errorbars

lc 5lc 7、およびlc 9がランダムに選択されているので、あなたのニーズにそれらを調整します。これは、gnuplotは4.6と結果です。線set bars 2は、バーの最後にチックを拡大します。

関連する問題