摘要: import matplotlib.pyplot as pltfrom mpl_toolkits.mplot3d import Axes3Dfrom sklearn import datasetsfrom sklearn.decomposition import PCAiris = datasets 阅读全文
posted @ 2020-06-14 21:39 逐梦无惧_数据分析 阅读(156) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport matplotlib.patches as mpatchesfrom sklearn import datasetsiris = datasets.load_iris()x = iris.data[:,0]y = iris. 阅读全文
posted @ 2020-06-14 21:21 逐梦无惧_数据分析 阅读(179) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npgs = plt.GridSpec(3,3)fig = plt.figure(figsize=(6,6))x1 = np.array([1,3,2,5])y1 = np.array([4,3,7,2]) 阅读全文
posted @ 2020-06-14 11:35 逐梦无惧_数据分析 阅读(165) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npfig = plt.figure()ax = fig.add_axes([0.1,0.1,0.8,0.8])inner_ax = fig.add_axes([0.6,0.6,0.25,0.25])x1 阅读全文
posted @ 2020-06-14 11:24 逐梦无惧_数据分析 阅读(154) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npfrom mpl_toolkits.mplot3d import Axes3Dx = np.arange(8)y = np.random.randint(0,10,8)y2 = y + np.rando 阅读全文
posted @ 2020-06-14 11:14 逐梦无惧_数据分析 阅读(287) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npfrom mpl_toolkits.mplot3d import Axes3Dxs = np.random.randint(30,40,100)ys = np.random.randint(20,30, 阅读全文
posted @ 2020-06-14 10:48 逐梦无惧_数据分析 阅读(475) 评论(0) 推荐(0) 编辑
摘要: from mpl_toolkits.mplot3d import Axes3Dimport matplotlib.pyplot as pltimport numpy as npfig = plt.figure()ax = Axes3D(fig)X = np.arange(-2,2,0.1)Y = n 阅读全文
posted @ 2020-06-14 10:33 逐梦无惧_数据分析 阅读(133) 评论(0) 推荐(0) 编辑
摘要: from mpl_toolkits.mplot3d import Axes3Dimport matplotlib.pyplot as pltfig = plt.figure()ax = Axes3D(fig)X = np.arange(-2,2,0.1)Y = np.arange(-2,2,0.1) 阅读全文
posted @ 2020-06-14 10:24 逐梦无惧_数据分析 阅读(155) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npN=8theta = np.arange(0.,2*np.pi,2*np.pi/N)radii = np.array([4,7,5,3,1,5,6,7])plt.axes([0.025,0.025,0. 阅读全文
posted @ 2020-06-14 10:16 逐梦无惧_数据分析 阅读(368) 评论(0) 推荐(0) 编辑
摘要: import matplotlib.pyplot as pltimport numpy as npdx = 0.01; dy = 0.01x = np.arange(-2.0,2.0,dx)y = np.arange(-2.0,2.0,dy)X,Y = np.meshgrid(x,y)#def f( 阅读全文
posted @ 2020-06-13 22:40 逐梦无惧_数据分析 阅读(137) 评论(0) 推荐(0) 编辑