![](https://img-blog.csdnimg.cn/20201014180756926.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Python
weixin_46338307
1234567890
展开
-
分类树在合成数集上的表现
分类树在合成数集上的表现导入需要的库import numpy as npimport matplotlib.pyplot as pltfrom matplotlib.colors import ListedColormapfrom sklearn.model_selection import train_test_splitfrom sklearn.preprocessing import StandardScalerfrom sklearn.datasets import make_moon原创 2021-02-09 17:08:42 · 80 阅读 · 0 评论 -
python_advanced_feature
集合推导式列表推导式%%timeit#普通方法result1 = []for i in range(10000): if i%2 == 0: result1.append(i)%%timeit#列表推导式方法result2 = [i for i in range(10000) if i%2 == 0]str_lst = ['Welcome', 'to', 'Python', 'Data', 'Analysis', 'Course']result3 = [x.u原创 2021-01-20 22:07:05 · 50 阅读 · 0 评论