read_csv_any_formats: Read a csv file using read_csv and avoid errors

View source: R/00-utils.R

read_csv_any_formatsR Documentation

Read a csv file using read_csv and avoid errors

Description

[Experimental] The csv file is read twice to detect the number of lines to use in attributing the column type ('guess_max' parameter of read_csv). This avoids common errors when reading csv files.

Usage

read_csv_any_formats(filename)

Arguments

filename

A character string of the path of the csv file.

Value

A tibble corresponding to the csv read.

See Also

readr::read_csv(), readr::read_csv2()

Examples

{

try(read_csv_any_formats(filename = tempfile()),silent = TRUE)

}


fabR documentation built on May 29, 2024, 2:58 a.m.