I have a CSV when I try to read.csv()
that file, I get the warning warning message:
In read.table(file = file, header = header, sep = sep, quote
Having a "proper" CSV file depends on the software that was used to generate it in the first place.
Consider Google Sheets. The warning will be issued every time that the CSV file -- downloaded via utils::download.file
-- contains less than five lines. This likely is related to the fact that (utils:read.table
):
The number of data columns is determined by looking at the first five lines of input (or the whole input if it has less than five lines), or from the length of
col.names
if it is specified and is longer.
In my short experience, if the data in the CSV file is rectangular, then the warning can be ignored.
Now consider LibreOffice Calc. There won't be any warnings, irrespective of the number of lines in the CSV file.