dotnet / corefxlab

This repo is for experimentation and exploring new ideas that may or may not make it into the main corefx repo.
MIT License
1.46k stars 347 forks source link

[DataFrame] Add a LoadCsv overload or other method that takes CSV content directly #2984

Closed jonsequitur closed 3 years ago

jonsequitur commented 3 years ago

Getting from a CSV string to a DataFrame requires some ceremony involving creating a stream first. While this might not be the ideal approach from a performance perspective for larger volumes of data, it's very useful for prototyping with sample subsets of data. An API like this will also play nicely with the .NET Interactive #!value magic command.

DataFrame.LoadCsvFromString(@"col1,col2,col3
1,2,3
4,5,6
");
pgovind commented 3 years ago

I think this is a good idea. I'll put a PR up for this soon and we can include this in the next preview