import pandas
hospital = pandas.read_excel("hospital.xls")
# 筛多个数据带条件的 sets = hospital[ (hospital['NEAR_FID'] != 1) & (hospital['NEAR_FID'] != 2) & (hospital['NEAR_FID'] != 3) ] # 迭代每一行 for i in sets.itertuples(): print(i[::])
import pandas
hospital = pandas.read_excel("hospital.xls")
# 筛多个数据带条件的 sets = hospital[ (hospital['NEAR_FID'] != 1) & (hospital['NEAR_FID'] != 2) & (hospital['NEAR_FID'] != 3) ] # 迭代每一行 for i in sets.itertuples(): print(i[::])