摘要:
3、以上模块都安完,设置扩展工具的参数找到setting->tools->external tools,点击加号新建工具 4、先加qtdesinger的参数,program:E:\python_study\qtstudy\venv\Lib\site-packages\pyqt5-tools\desi 阅读全文
摘要:
#k-means聚类分析 数据标准化zcdata=(cdata-cdata.mean())/cdata.std()zcdata.head()from sklearn.cluster import KMeanskmodel=KMeans(n_clusters=4,n_jobs=4,max_iter=1 阅读全文
摘要:
import pandas as pdfrom datetime import datetimefrom math import ceil #向上取整from pandas import DataFramedata=pd.read_excel('./data/data5.xlsx',encoding 阅读全文
摘要:
#异常值的处理import pandas as pdimport numpy as npSegData=pd.read_csv('./data/data1.csv',encoding='gbk')SegData.head()SegData.describe().TSegData.loc[:,'供应商 阅读全文
摘要:
#缺失值的处理from pandas import Seriesimport numpy as npstringSer=Series(['a','b',np.nan,'d','e'])#isnull 显示空值 stringSer.isnull()#notnull 显示非空值stringSer.not 阅读全文
摘要:
import pandas as pddf1=pd.DataFrame({'key':['a','b','c'],'data1':range(3)})df2=pd.DataFrame({'key':['a','b','d'],'data2':range(3)})pd.merge(df1,df2) # 阅读全文
摘要:
import pandas as pdpivot_data=pd.read_excel('./data/data3.xlsx')pivot_data.head()pivot_data.describe(include='all').T import numpy as np#透视表 求进货价合计、平均 阅读全文
摘要:
import pandas as pddf2=pd.read_excel('./data/data2.xlsx',index_col='产品编码')df2.head()x=df2['供应商进货价']y=df2['销售价']from pylab import mplmpl.rcParams['font 阅读全文
摘要:
import pandas as pd df1=pd.read_csv("./data/data1.csv",encoding='gbk',index_col='产品编码')print(df1.head())#获得数据print(len(df1))print(df1.index.size)#求均值m 阅读全文
摘要:
#执行这个爬虫文件 scrapy crawl spider51job 阅读全文