tabreader - read in tabular datafiles in text in the tab format; yes, uses values = line.split("/t")


(Gerald Bauer) #1

Hello,

  I've put together a new library / gem, that is, tabreader
that lets you read in tabular datafiles in text in the tab format;
yes, uses

   values = line.split( "/t" )

or use the packaged up

   TabReader.parse_line( ... )

or any of the convenience helpers incl. TabHashReader.parse
for returning hashes (with named value pairs) instead of arrays
(with a list of values by position/index).

The readme includes why CSV.read( col_sep: "\t", quote_char: "∅" )
is NOT recommended (and broken) and why tab is its own (simpler) format
than the classic comma-separated values (csv) format.

   Happy data wrangling with ruby. Cheers. Prost.

[1] https://github.com/datatxt/tabreader