[Tutor] Parsing large files

Karl Fast karl.fast at pobox.com
Fri Feb 6 13:25:01 EST 2004


> I have a text file that is tab delimited.. it has 321 columns with
> over 1000 rows.. I need to parse this out to 2 text files with
> roughly half

You might want to try the CSV module that is a standard module as of
Python 2.3. I have not used it, but it should do the trick for you.
The default separator is a comma but you can easily make it a tab.

http://www.python.org/doc/current/lib/module-csv.html


--karl



More information about the Tutor mailing list