read_files: Read a GTFS text file

View source: R/import_gtfs.R

read_filesR Documentation

Read a GTFS text file

Description

Reads a GTFS text file from the main .zip file.

Usage

read_files(file, gtfs_standards, fields, extra_spec, tmpdir, quiet, encoding)

Arguments

file

A string. The name of the file (without .txt extension) to be read.

gtfs_standards

A named list. Created by get_gtfs_standards.

fields

A named list. Passed by the user to import_gtfs.

extra_spec

A named list. Passed by the user to import_gtfs.

tmpdir

A string. The path to the temporary folder where GTFS text files were unzipped to.

quiet

Whether to hide log messages and progress bars (defaults to TRUE).

encoding

A string. Passed to fread, defaults to "unknown". Other possible options are "UTF-8" and "Latin-1". Please note that this is not used to re-encode the input, but to enable handling encoded strings in their native encoding.

Value

A data.table representing the desired text file according to the standards for reading and writing GTFS feeds with R.

See Also

get_gtfs_standards


gtfsio documentation built on Oct. 20, 2023, 9:08 a.m.