Home
Reading
Searching
Subscribe
Sponsors
Statistics
Posting
Contact
Spam
Lists
Links
About
Hosting
Filtering
Features Download
Marketing
Archives
FAQ
Blog
 
Gmane
From: Chris Barker <Chris.Barker <at> noaa.gov>
Subject: Re: rank-0 arrays
Newsgroups: gmane.comp.python.numeric.general
Date: Monday 16th September 2002 18:35:16 UTC (over 14 years ago)
Travis Oliphant wrote:

> This is the gist of it.  Basically you extend the Python scalars to
> include the single precision types (all the types Numeric supports).

Would they be recognised as scalars by Python? In particular, could you
use one as an index? Personally, this is what has bit me in the past: I
could use A[3,2] as an index if A was type "Int" but not if it was
"Int16" for example.

In any case, the type of A[3,2] should NOT depend on the precision of
the numbers stored in A.

Frankly, I have no idea what the implimentation details would be, but
could we get rid of rank-0 arrays altogether? I have always simply found
them strange and confusing... What are they really neccesary for
(besides holding scalar values of different precision that standard
Pyton scalars)?

-Chris







-- 
Christopher Barker, Ph.D.
Oceanographer
                                    		
NOAA/OR&R/HAZMAT         (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[email protected]
 
CD: 19ms