Lionel Roubeyrie wrote:
> Hi Torgil,
> strange, I don't have the same error:
>
> |~|[2]>array(['2'],dtype=float32)
> ---
> exceptions.ValueErrorTraceback
Hi Torgil,
strange, I don't have the same error:
|~|[2]>array(['2'],dtype=float32)
---
exceptions.ValueErrorTraceback (most recent
call last)
/home/lione
Torgil Svensson wrote:
> It works if you replace the strings '2','3','5','6' with numbers instead.
duh! I can't believe I didn't see that!
-Chris
--
Christopher Barker, Ph.D.
Oceanographer
Emergency Response Division
NOAA/NOS/OR&R(206) 526-6959 voice
7600 Sand Point Way NE (2
It works if you replace the strings '2','3','5','6' with numbers instead.
This case got a better error-message:
>>> array(['2'],dtype=float32)
Traceback (most recent call last):
File "", line 1, in ?
TypeError: a float is required
//Torgil
On 11/29/06, Lionel Roubeyrie <[EMAIL PROTECTED]> wr
Lionel Roubeyrie wrote:
> Hi all,
> I don't understand why can't I do that:
> b=array([(datetime.datetime(2006,11,29),'2','3'),
> (datetime.datetime(2006,11,30),'5','6')], dtype=[('Dates', 'object'),
> ('HUM', 'float32'), ('TEM', 'float32')])
> ValueError: tried to set void-array with object member
Hi all,
I don't understand why can't I do that:
b=array([(datetime.datetime(2006,11,29),'2','3'),
(datetime.datetime(2006,11,30),'5','6')], dtype=[('Dates', 'object'),
('HUM', 'float32'), ('TEM', 'float32')])
ValueError: tried to set void-array with object members using buffer.
Thanks
--
Lionel R