谁来帮我???????
用户:
蔡宁进(大家再见)查看:1 回复:1 评论:1 创建时间:2020-12-13T20:09:57
这什么问题(标红字幕)?
import requests import cutecharts as cu rep = requests.get('
http://api.map.喵/weather/v1/?' 'district_id=110100' '&data_type=all' '&ak=UwsCZVnSzygXUIpoQOq3w3NLCbxNGajL')
for i in range(70): pass dis_id = 310100+i*100 url = '
http://api.map.喵/weather/v1/?district_id=' + \ str(dis_id) +\ '&data_type=all&ak=UwsCZVnSzygXUIpoQOq3w3NLCbxNGajL' rep = requests.get(url) rep.encoding = 'utf-8'
if rep.json()['status'] == 0 city.append(rep.json()['result']['location']['city']) temp.append(rep.json()['result']['now']['temp']) chart.set_options( labels=city, x_label="" ) chart.width = "1200px" chart.add_series("最高温度", temp) chart.render("city.html")
回复
上一页第 1 页 / 共 1 页下一页