parse csv to arrays