octave-maintainers
[Top][All Lists]
Advanced

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

Re: Patch Re: iterating cell arrays


From: David Bateman
Subject: Re: Patch Re: iterating cell arrays
Date: Thu, 24 Jun 2004 10:32:04 +0200
User-agent: Mutt/1.4.1i

Daprès Paul Thomas <address@hidden> (le 23/06/2004):
> R12 is well behaved;
> 
> for i = { 'a',  'b' } ; disp(i) ; end
> 
> or
> 
> x = { 'a' , 'b' } ; for i = x ; disp(i) ; end
> 
> behave as they ought to by outputting

but 

>> a = 0; for i = {'a', 'b'; 'c', 'd'}; disp(a); a=a+1;disp(i); end
     0

    'a'
    'c'

     1

    'b'
    'd'


So the behave of the cell array is to iterate over the columns of 
the array, as it does for a matrix. However, R12 does wierd things
for an NDarray where it continues it iterate over the columns. So
I'd like to see what an R13 or R14 version of matlab does with NDarrays
rather than implement such broken behaviour...

Cheers
David
-- 
David Bateman                                address@hidden
Motorola CRM                                 +33 1 69 35 48 04 (Ph) 
Parc Les Algorithmes, Commune de St Aubin    +33 1 69 35 77 01 (Fax) 
91193 Gif-Sur-Yvette FRANCE

The information contained in this communication has been classified as: 

[x] General Business Information 
[ ] Motorola Internal Use Only 
[ ] Motorola Confidential Proprietary



reply via email to

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