Export from pdf to matlab

7 次查看(过去 30 天)
Is it possible to export the data table from the pdf to matlab? The data in the pdf are saved as text. I would like to copy this data and save it as a matrix.

采纳的回答

Walter Roberson
Walter Roberson 2023-2-23
-- requires the Text Analytics Toolbox
Reading data from PDF can be a technical challenge. PDF is not designed as a "data container" plus "commands to format containers" like CSS can be. PDF is a Page Description Language, and consists of commands to move to particular positions, draw this and that, and so on.
For example, 'fifth' might be stored in the file as a position for the leading 'f' and then a position for the second 'f', and then a position to draw a single symbol that is a 'th' ligature, and then a position to draw the 'i' close to the first 'f' .
The number of symbols encoded is not necessarily the same as the number of characters, and the positions are not generally one after the other. And the command language includes loops. For example the two 'f' of 'fifth' might be done by preparing an 'f' symbol and then a single command to composite the one symbol to two different locations.
To extract text semi-reliably from a page description language, you have to execute the commands and figure out what the result was.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Text Data Preparation 的更多信息

产品


版本

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by