【发布时间】:2018-04-27 19:51:57
【问题描述】:
我正在尝试使用以下 Python 代码从 EDGAR 数据库中获取一些数据。
html1 = 'https://www.sec.gov/Archives/edgar/data/320193/000032019317000070/aapl-20170930.xml'
xbrl_resp = requests.get(html1)
xbrl_str = xbrl_resp.text
soup1 = BeautifulSoup(xbrl_str, 'lxml')
mytag = soup1.find('us-gaap:StockholdersEquity',{'contextRef':'FI2017Q4'})
print(mytag)
即使标记存在于 xml 文件中,它也不会返回任何内容。任何建议将不胜感激
【问题讨论】: