help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Probable xlsread bug


From: Olivier Lefevre
Subject: Probable xlsread bug
Date: Sat, 29 Dec 2007 03:10:51 +0100
User-agent: Thunderbird 2.0.0.9 (Windows/20071031)

If you read in, e.g.,

   6.9,5.2,6.3
   7.3,,6.2

(that is, the tabbed equivalent) the 3x3 matrix that comes out is not

   6.9 5.2 6.3
   7.3 NaN 6.2

as you'd expect but

   6.9 5.2 6.3
   7.3 6.2 NaN

i.e., I assume it skipped the missing value and the NaN that comes
out in the back is the padding needed to make the array rectangular.
Thus you'll (usually) get the right number of NaNs but in the wrong
places! SciLab's readxls gives what you'd expect. I don't have MatLab
at the ready to check but it sure looks like a bug: if it were a
deviation I assume the help entry for xlsread would warn you about
it, no?

In addition it's obscenely slow: I think it takes like 30s to read
a 1500 x 20 matrix. I wrote my own version to "do the right thing"
and it's slow, too: the line tokenizing and number parsing are the
culprits, probably also with the original xlsread. SciLab is fast
but that isn't an apple-to-apple comparison since it works directly
on binary *.xls files.

-- O.L.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]