cellar
Ruby gem to deal with cells of data in rows and columns (CSV, spreadsheets, etc.)
Example
Sample code:
# read CSV
data = DATA.read
rows = data.split("\n").map {|line| line.split(",") }
# show output
info = Cellar.new(rows)
info.each do
p info[:id, 4, "name", "gym".."age", 6..4, :color, "CaNdY"]
end
__END__
Sample output:
["1", "Gold's", "joe", "Gold's", "Rockville", "13", "gum", "yellow", "Gold's", "yellow", "gum"]
["2", "24 Hour Fitness", "sally", "24 Hour Fitness", "Melville", "8", "skittles", "pink", "24 Hour Fitness", "pink", "skittles"]
["3", "Couch", "curly", "Couch", "Vegas", "44", "Snicker's", "purple", "Couch", "purple", "Snicker's"]