plotfile: tuple index out of range

Hi,

I can't get the plotfile command to work on a simple file. I have
a file"tester.txt" which looks like:

      1 0.2137 0.2139 0.2138
      2 0.3969 0.3970 0.4003
      3 0.4391 0.4396 0.4382
      4 1.0020 1.0040 1.0020
      5 0.4892 0.4893 0.4903
      6 0.1593 0.1595 0.1589
      7 0.1658 0.1659 0.1665

Now (from ipython):
In [41]: plotfile("tester.txt",cols=(0,1))

···

---------------------------------------------------------------------------
IndexError Traceback (most recent call last)

....

)
    1436 return identifier, r[identifier]
    1437 elif is_numlike(identifier):
-> 1438 name = r.dtype.names[int(identifier)]
    1439 return name, r[name]
    1440 else:

IndexError: tuple index out of range

There must be a very simple explanation for this, but I haven't found it. (By the way, I tied with and without column headers, no difference).
I'm running MPL 0.98.3 on an Ubuntu 8.10 system.

Thanks,

Dave

The default delimiter is ‘,’. You need space. Eg

plotfile(“tester.txt”, cols=(0,1), delimiter=’ ’ )

···

On Tue, Mar 17, 2009 at 2:18 AM, David Simpson <david.simpson@…2017…> wrote:

Now (from ipython):

In [41]: plotfile(“tester.txt”,cols=(0,1))


IndexError Traceback (most recent call last)

)

1436             return identifier, r[identifier]

1437         elif is_numlike(identifier):

-> 1438 name = r.dtype.names[int(identifier)]

1439             return name, r[name]

1440         else:

IndexError: tuple index out of range