摘要:
python. pandas(series,dataframe,index,reindex,csv file read and write) method test import pandas as pdimport numpy as np def testpandas(): p = pd.Seri 阅读全文
摘要:
#read and write csv of pandasimport pandas as pdgoog =pd.read_csv(r'C:\python\demo\LiaoXueFeng\data\test_vrt.csv',index_col=0)goog=goog.reindex(pd.to_ 阅读全文
摘要:
1.切片:截取List,tuple指定范围内的值:>>L[0,3] 2.如果给定一个list或tuple,我们可以通过for循环来遍历这个list或tuple,这种遍历我们称为迭代(Iteration)。 在Python中,迭代是通过for ... in来完成的 for x in L print(x 阅读全文
摘要:
dict and set dict: 键-值 /重复添加 set : 键 / key不能重复 对于不变对象来说,调用对象自身的任意方法,也不会改变该对象自身的内容。相反,这些方法会创建新的对象并返回,这样,就保证了不可变对象本身永远是不可变 Python内置了字典:dict的支持,dict全称dic 阅读全文
摘要:
1. environment building and config 2. variable and data type 数据类型,浮点数(1.2e3,1.3e-2), 字符串("",'',"'") ('i\' m \"ok\"!') \\ r'asdfasfa' \n '''adsadf''' 布 阅读全文
摘要:
part 1 python language 1. environment building and config 2. variable and data type 3. programming basis 4. decorator python example 5. http and urlli 阅读全文