One question at a time: You cannot output Data trees yet with a Script component. Only single lists. You may have to break apart your code into 2 Scripts, one that parses the file and outputs lines of text, the other that parses the lines and outputs numbers.
-- David Rutten da...@mcneel.com Robert McNeel & Associates