Added samples for loading text - #3793
Conversation
| private static void PrintRowCount(IDataView idv) | ||
| { | ||
| // IDataView is lazy so we need to iterate through it | ||
| // to get the number of rows. |
There was a problem hiding this comment.
Could you also print out the first and the last lines in the loaded file?
There was a problem hiding this comment.
The information I'm trying to convey here is how many files were loaded using each of the Load() variants (1 or 5 files). Count of rows is best for that. I don't think the user can know what's the first line and what's the last one, since the rows are randomly generated. That info won't be super relevant.
In reply to: 289104819 [](ancestors = 289104819)
| var fileName = Path.Combine(dataDirectoryName, $"Data_{i}.csv"); | ||
| dataFiles.Add(fileName); | ||
| using (var fs = File.CreateText(fileName)) | ||
| // Write random lines without header |
There was a problem hiding this comment.
Could we have another example with header?
There was a problem hiding this comment.
this is an example for Load() method and all it's variants. header applies to creating the loader itself. I'll add that separately to CreateTextLoader() API.
In reply to: 289105567 [](ancestors = 289105567)
Fix #2457