Process data from csv file