From: Paul K. <pki...@us...> - 2006-01-14 05:58:08
|
Laurent, I applied your fix to octave-forge. Someone with a working 2.9.x will have to check if the fix is needed there as well. Here's the test: assert (cell2mat({1, 2, 3}), [1, 2, 3]); assert (cell2mat({1; 2; 3}), [1; 2; 3]); See attached for Laurent's fix as a patch to the current octave CVS. * general/cell2mat.m: support 1D cell argument. - Paul On Jan 13, 2006, at 12:16 PM, Laurent Mazet wrote: > On Thu, 8 Dec 2005 21:31:56 +0800 > William Poetra Yoga Hadisoeseno <wil...@gm...> wrote: > ... > > Hi, > > Sorry I'm late to comment the post. > > First, I found a bug on 1D cell argument (file attached). I will > update the > octave-forge version as soon I managed to boot again my own coputer (HD > controler broken :-( ) > > Seconldy, I read the code you added for dimension and type checking > but I don't > think it's efficient for a such function. This type of function has to > been run > as fast as possible and usualy no-ones care of the error message > (except > during the debugging process). From my point of view, cell2mat don't > have to > waste time on input checking. > > Laurent > -- > Dr. Laurent Mazet: Research Engineer /V\ Centre de Recherche de > MOTOROLA > Tel: +33 1 69 35 48 30 =-=-=-=-=-=-=-= Email: > lau...@mo... > <cell2mat.m> |