def fetch(self):
"""
Fetches the list of deputies for the current term.
"""
xml = urllib.request.urlopen(self.URL)
tree = ET.ElementTree(file=xml)
records = self._parse_deputies(tree.getroot())
df = pd.DataFrame(records, columns=(
'congressperson_id',
'budget_id',
'condition',
'congressperson_document',
'civil_name',
'congressperson_name',
'picture_url',
'gender',
'state',
'party',
'phone_number',
'email'
))
return self._translate(df)
deputies_dataset.py 文件源码
python
阅读 20
收藏 0
点赞 0
评论 0
评论列表
文章目录