pandas で scatter matrix
pandas (Python Data Analysis Library)
http://pandas.pydata.org/
iris データを対象として scatter matrix を描画した。
>>> from pandas import * >>> from pandas.tools.plotting import * >>> import matplotlib.pyplot as plt >>> data = read_csv('iris.csv') >>> scatter_matrix(data) array([[Axes(0.125,0.7;0.19375x0.2), Axes(0.31875,0.7;0.19375x0.2), Axes(0.5125,0.7;0.19375x0.2), Axes(0.70625,0.7;0.19375x0.2)], [Axes(0.125,0.5;0.19375x0.2), Axes(0.31875,0.5;0.19375x0.2), Axes(0.5125,0.5;0.19375x0.2), Axes(0.70625,0.5;0.19375x0.2)], [Axes(0.125,0.3;0.19375x0.2), Axes(0.31875,0.3;0.19375x0.2), Axes(0.5125,0.3;0.19375x0.2), Axes(0.70625,0.3;0.19375x0.2)], [Axes(0.125,0.1;0.19375x0.2), Axes(0.31875,0.1;0.19375x0.2), Axes(0.5125,0.1;0.19375x0.2), Axes(0.70625,0.1;0.19375x0.2)]], dtype=object) >>> plt.show()
適当にやったところ,"class" 列は文字列のためか,勝手に除いてくれた。