check_csv_file: Check if the csv file has a correct format

Description Usage Arguments Value Examples

Description

Check if the csv file has a correct format

Usage

1
2
check_csv_file(file, noconfirm = FALSE, filename = NULL,
  outfile = NULL)

Arguments

file

The file's path

noconfirm

A logical, this parameter indicates if the user must confirm to change the name of the file and save in different file

filename

A character, if this parameter is present then the name of the file will be automatically set

outfile

A character the path where the file will be save if it need to be modify, NULL to use the file's directory

Value

A logical

Examples

1
2
3
4
5
6
library(dataesgobr)
file <- system.file("extdata", "fichero.csv", package="dataesgobr")
correct <- check_csv_file(file, noconfirm = TRUE)
correct <- check_csv_file(file, noconfirm = TRUE, outfile = tempdir())
correct <- check_csv_file(file, noconfirm = TRUE, filename = "nuevo.csv")
correct <- check_csv_file(file, noconfirm = TRUE, outfile = tempdir())

dataesgobr documentation built on June 18, 2019, 5:04 p.m.