How to get the row index of a csv file using ```for row in CSV.File(filename)```?


#1

Hi, I plan to read a .csv file using for row in CSV.File(filename) like the following:

for row in CSV.File(filename) 
      # parse the information stored in this row to a vector of my defined type
end

Now, I need to know the row index. Is there a simple way to get the row index from this setting?
Thank you.


#2

for (i, row) in enumerate(…)


#3

@dpsanders, you mean

for (i,row) in enumerate(CSV.File(filename))

?