2015-03-25 37 views

回答

3

它,因为你设置unpack=True,解包调换你的阵列。

从numpy的文档:

unpack : bool, optional 

If True, the returned array is transposed, so that arguments may be 
unpacked using x, y, z = loadtxt(...). When used with a record data-type, 
arrays are returned for each field. Default is False.` 

如果你把它设置为false,它不会转的阵列。

+0

谢谢!我也发现genfromtxt做同样的事情。 – 2015-03-25 03:51:19