Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fread with single line text #4689

Closed
trainormg opened this issue Aug 31, 2020 · 0 comments · Fixed by #4703
Closed

fread with single line text #4689

trainormg opened this issue Aug 31, 2020 · 0 comments · Fixed by #4703
Labels
Milestone

Comments

@trainormg
Copy link

When calling fread with the text="content,to,parse" the behaviour is not as expected if the value is a string without a newline.
In that case, the value of text= is interpreted as a file name, the same behaviour of the input= parameter.

Example:

> fread(text = "a,b,c")
Error in fread(text = "a,b,c") : file not found: a,b,c 

I expected a data.table with three columns (a, b, c) and no rows, or a data.table with one row and columns V1, V2, V3, depending on the value of col.names.

R version 3.6.3 (2020-02-29)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants