我有一个pdf文件与表格在其中,并希望阅读它作为一个数据文件使用表格。但是只有第一页有列标题。在读时使用
tabula.read_pdf(pdf_file, pages='all', lattice = 'True')数据以所需的格式出现,所有页面都被正确地提取,但是
pd.DataFrame(tabula.read_pdf(pdf_file, pages='all', lattice = 'True')只显示了几行。
发布于 2022-11-30 10:08:58
你应该这样做(假设你的pdf不包含文本和表格)
table = tabula.read_pdf(pdf_file, pages='all',output_format="dataframe" ,lattice = 'True')https://stackoverflow.com/questions/74624251
复制相似问题