From bug-octave-request at bevo dot che dot wisc dot edu Sat Nov 29 20:34:48 2003 Subject: Incorrect dimensions of subarrays of ND Arrays From: Quentin Spencer To: bug-octave at bevo dot che dot wisc dot edu Date: Sat, 29 Nov 2003 20:34:12 -0600 First, I want to thank all of those who have worked to make Nd arrays possible. I am testing some MATLAB scripts that use ND arrays in octave and got the following problem: > a=ones(4,5,6); > size(a) ans = 4 5 6 > size(a(1:2,:,4)) ans = 2 5 1 In MATLAB, this returns a matrix of dimension [2,5]. The fact that this returns a 3 dimensional array broke an assignment operation in one of my scripts where a 2-dimensional "slice" of a 3-dimensional array was assigned to a part of a 2-dimensional array. -Quentin ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------