Reads a table from a text file or a directory of text files. Resulting table will consist of a single column data, have the number of rows equal to the number of lines in the file. Each cell will contain a single line from the file.
In case the folder is specified, and there are several files placed in the folder, their order is determined according to to their modification times: the smaller the modification time is, the earlier the file will be passed to the engine.
- path (
str) – Path to a file or to a folder.
- poll_new_objects (
bool) – If set to true, the engine will wait for the new input files in the folder.
- debug_data – Static data replacing original one when debug mode is active.
- path (
The table read.
- Return type
>>> import pathway as pw>>> t = pw.plaintext.read("raw_dataset/lines.txt")