# Maple: How to parse such CSV (Comma Separated Values) document?

So I have a large txt file with such contents (like 20mbs long)

20 30 40 550 60 70 80 91
20 30 40 50 60 70 80 92
20 30 40 50 60 70 80 93
20 30 40 50 64 70 80 90
20 30 40 50 60 70 80 90
20 30 40 50 60 70 80 90
20 30 40 40 60 70 80 90
40 30 40 50 60 70 80 90

4 5 6 6

20 30 40 50 60 70 80 91
20 30 40 50 60 70 80 92
20 30 40 50 60 70 80 93
2 30 40 50 64 70 80 90
20 30 20 50 60 70 80 90
20 30 40 50 60 70 80 90
20 30 40 40 60 70 80 90
40 30 40 50 60 70 80 90

4 5 1 6

20 30 40 50 60 70 80 91
20 30 40 50 60 70 80 92
20 30 40 50 60 70 80 93
20 30 40 50 64 70 80 90
20 30 40 50 60 70 80 90
20 30 40 50 60 70 80 90
20 1 40 40 60 70 80 90
40 30 40 50 60 70 80 90

4 5 6 1


I want to get out of that document an array of matrices 8x8 and an array of matrices 1*4 is such thing possible and how to do it?

I need such thing to get data to train NN.

-
You might be better off asking this question on stackoverflow.com. –  Rudy the Reindeer Feb 1 '11 at 13:17

And this is the Maple Helpfile for the "ImportData" function. However, Maple is not as powerful as Mathematica or Matlab concerning external data and you might have to preprocess the data to a form which allows Maple to handle it correctly.

Also I agree that you should rather ask on a programming platform.

-