Reading Data Table
- To: mathgroup at smc.vnet.net
- Subject: [mg119931] Reading Data Table
- From: fractal11 <trchan at mit.edu>
- Date: Thu, 30 Jun 2011 06:30:39 -0400 (EDT)
Is there a way to read a file with a user specified word separator and record separator, such that the result is a list of lists of words? For example, a file containing "1 2 3\n4 5 6" would become {{1,2,3}, {4,5,6}}. Import does almost exactly what I want, although I can't figure out how to change the word and record separators. In particular, I have a file where word separators are tab characters, but the data themselves have spaces. Therefore, Mathematica's default word separator of whitespace does not work.
- Follow-Ups:
- Re: Reading Data Table
- From: "McHale, Paul" <Paul.McHale@excelitas.com>
- Re: Reading Data Table