このページの2つのバージョン間の差分を表示します。
01_linux:02_www:21_gnuplot [2017/06/22 05:59] – 作成 matsui | 01_linux:02_www:21_gnuplot [2017/06/22 08:32] (現在) – [エラー] matsui | ||
---|---|---|---|
行 1: | 行 1: | ||
+ | ====== 21 グラフ描写(gnuplot) ====== | ||
+ | |||
+ | ===== インストール ===== | ||
+ | |||
+ | [[http:// | ||
+ | |||
+ | === yum === | ||
+ | |||
+ | < | ||
+ | # yum install gnuplot | ||
+ | </ | ||
+ | |||
+ | === ソースから === | ||
+ | |||
+ | < | ||
+ | # tar zxvf gnuplot-5.0.6.tar.gz | ||
+ | # cd gnuplot-5.0.6 | ||
+ | # ./configure --prefix=/ | ||
+ | # make && make install | ||
+ | </ | ||
+ | |||
+ | |||
+ | ==== 使い方 ==== | ||
+ | |||
+ | これで、image.pngというファイルができる。 | ||
+ | < | ||
+ | # gnuplot | ||
+ | gnuplot> set terminal png | ||
+ | gnuplot> set out ' | ||
+ | gnuplot> set title ' | ||
+ | gnuplot> plot sin(x) w line lc rgb ' | ||
+ | gnuplot> quit | ||
+ | </ | ||
+ | |||
+ | {{: | ||
+ | |||
+ | ==== エラー ==== | ||
+ | |||
+ | |||
+ | Could not find/open font when opening font " | ||
+ | |||
+ | フォントが無いですよ。というエラー | ||
+ | 下記を環境変数を設定してあげるとフォントが綺麗になる。 | ||
+ | |||
+ | export GDFONTPATH=/ | ||
+ | export GNUPLOT_DEFAULT_GDFONT=VL-Gothic-Regular | ||
+ | |||
+ | |||
+ | {{tag> |