Jaroslav Hajek | 2 Feb 2010 13:59
Picon

Re: typecast sometimes produces a column vector, not a row vector

On Mon, Feb 1, 2010 at 4:23 PM,  <vermeij <at> nurc.nato.int> wrote:
> To: bug <at> octave.org
> Cc: arjan
> Subject: typecast sometimes produces a column vector, not a row vector
> --------
> Bug report for Octave 3.0.1 configured for i486-pc-linux-gnu
>
> Description:
> -----------
>
> In general the typecast function produces a row vector.
> In some cases, however, it produces a column vector.
>
> Repeat-By:
> ---------
>
> According to the manual (help typecast)
>
>    X = uint16 ([1, 65535]);
>    typecast (X, 'uint8')
>
> produces
>
>     1    0  255  255
>
> This works. I would expect then this
>
>    X = uint16 ([65535]);
>    typecast (X, 'uint8')
>
> to produce
>
>     255  255
>
> Instead it produces
>
>     255
>     255
>

This seems to be fixed in the development sources.

--

-- 
RNDr. Jaroslav Hajek, PhD
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz

Gmane