x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] # Creating data points y as a function of x. Squares of x, Cubes of x, Reverse of x, Fibbonacci places of x ...
上記の記事を読んでつまづいたところのメモ。 pyplotはグラフなんかを表示するためのモジュール。 なんとなくは知ってるけど使いこなせてはいないので、改めて使い方を確認。 matplotlib.pyplotをインポート import matplotlib.pyplot as plt pyplotのインポート。 みたい ...
最近,研究活動(おもに実験)で得たデータを計算したり,可視化するのに使っているPython。可視化(グラフ作成)に使うMatplotlib(Seaborn)の使い方をすぐ忘れてしまうので,自分のために書き留めておこうと思う。 x = np.linspace(1,100,100) y = x**2 一番簡単なプロット ...
# Turning on the grid for x axis and saving the plot # plt.grid(True, axis='x') # plt.savefig("Plots/fig_with_grid_x.png") # Turning on the grid for y axis and saving ...
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 ...