最近,研究活動(おもに実験)で得たデータを計算したり,可視化するのに使っているPython。可視化(グラフ作成)に使うMatplotlib(Seaborn)の使い方をすぐ忘れてしまうので,自分のために書き留めておこうと思う。 x = np.linspace(1,100,100) y = x**2 オブジェクト指向な ...
ある単位について、それと連動する他の量がある場合、参考のため、上下や左右に違う目盛りを振りたくなることがあります。そのスクリプト例。尺度の変換の行きと帰り両方の関数を用意してやって、あたえればよいそうです。 下の目盛りは光の波長、上 ...
Often it is desirable to have a second x or y scale on an axes with a different scale than the primary x/y axis; think frequency and period on the xaxis of a power spectrum, or date and datenum for a ...
This is not a lien on the 4.11 release. With the CIAO 4.11 code base (so close to master) and matplotlib version 2.2.3, I see the following behavior, where some, but not all calls to plot ...
It is possible to set a logarithmic scale for one or both axes. This functionality is in fact only one application of a more general transformation system in Matplotlib. Each of the axes' scales are ...