(2011/05/20 元記事)
けっこう前にpm3dの使い方をまとめた
デフォルトだと色合いはこんな感じ
これを変えてみたい
まずはgnuplotを起動して
help set palette rgbformulae
と打ってみる。次のような説明が出てくる。
%help set palette rgbformulae
For `rgbformulae` three suitable mapping functions have
to be chosen. This is done via `rgbformulae <r>,<g>,<b>`. The available
mapping functions are listed by `show palette rgbformulae`. Default is
`7,5,15`, some other examples are `3,11,6`, `21,23,3` or `3,23,21`. Negative
numbers, like `3,-11,-6`, mean inverted color (i.e. 1-gray passed into the
formula, see also `positive` and `negative` options below).Some nice schemes in RGB color space
7,5,15 ... traditional pm3d (black-blue-red-yellow)
3,11,6 ... green-red-violet
23,28,3 ... ocean (green-blue-white); try also all other permutations
21,22,23 ... hot (black-red-yellow-white)
30,31,32 ... color printable on gray (black-blue-violet-yellow-white)
33,13,10 ... rainbow (blue-green-yellow-red)
34,35,36 ... AFM hot (black-red-yellow-white)A full color palette in HSV color space
3,2,2 ... red-yellow-green-cyan-blue-magenta-redPlease note that even if called `rgbformulae` the formulas might actually
determine the <H>,<S>,<V> or <X>,<Y>,<Z> or ... color components as usual.Use `positive` and `negative` to invert the figure colors.
Note that it is possible to find a set of the best matching rgbformulae for any
other color scheme by the command
show palette fit2rgbformulae
要するに
set palette rgbformulae <r>,<g>,<b>
括弧の中には数字を入れて、上のように打ったら色合いが変化する
試しに、helpで出てきた組み合わせについてsplotしてみる
7,5,15 ... traditional pm3d (black-blue-red-yellow)
3,11,6 ... green-red-violet
23,28,3 ... ocean (green-blue-white)
21,22,23 ... hot (black-red-yellow-white)
30,31,32 ... color printable on gray (black-blue-violet-yellow-white)
33,13,10 ... rainbow (blue-green-yellow-red)
34,35,36 ... AFM hot (black-red-yellow-white)
3,2,2 ... red-yellow-green-cyan-blue-magenta-red
自分が使うとしたら、AFM hotかなー
もしこの設定を今後のデフォルトにしたいのなら、
set palette rgbformulae 23,24,25
と .gnuplot という設定ファイルに書いておけば大丈夫でしょう