[SciPy-user] read_array problem

Steve Schmerler elcorto@gmx....
Tue Jan 8 16:32:30 CST 2008


Johann Cohen-Tanugi wrote:
> hi, I followed the advice and looked at the docstring :
> Help on function loadtxt in module numpy.core.numeric:
>
> loadtxt(fname, dtype=<type 'float'>, comments='#', delimiter=None,
> converters=No
> ne, skiprows=0, usecols=None, unpack=False)
>     Load ASCII data from fname into an array and return the array.
>
>     The data must be regular, same number of values in every row
>
>     fname can be a filename or a file handle.  Support for gzipped files is
>     automatic, if the filename ends in .gz
>
>     See scipy.loadmat to read and write matfiles.
>  ....
>
> Beyond the fact that it comes a bit as a surprise that numpy refers to
> loadmat from a distinct package (well, sometimes I wonder how distinct
> scipy and numpy are meant to be.... as a matter of fact
> help(scipy.loadtxt) will work as well and give you the same info), this
> scipy.loadmat does not seem to exist.... Maybe scipy.load was intended?
> best,
> Johann
>

I think scipy.io.loadmat is correct.

cheers,
steve



More information about the SciPy-user mailing list