该楼层疑似违规已被系统折叠 隐藏此楼查看此楼
自学了一点Python...爬取了基金网的一点数据 ,不知道怎么才能把 爬取的数据写到Excel 中 求指教
import requests
import re
#url1=('http://fundgz.1234567.com.cn/js/161726.js?')
#url2=('http://fundgz.1234567.com.cn/js/501009.js?')
#url3=('http://fundgz.1234567.com.cn/js/110023.js?')
zixuan=['161726','501009','110023','000452','161725','110022','001631','001632','002621','001410','001618','006751','001593','004744','000854','110011','000751','206009','161024','001553','000217']
for i in zixuan:
url="http://fundgz.1234567.com.cn/js/"+i+".js?"
#print(url)
html = requests.get(url)
strr = html.text
#print(strr)
data = []
pat1=r'"