From: dpb on
Priom Rahman wrote:
> Thanks guys for your promt replies !
>
> both of those worked !!
>
> m=M';m=m(:)';
> & m =reshape(M.',1,[])
>
> =)

Yes, we knew they were equivalent; simply different syntax.

Did you time them to see if there's any difference in execution speed?

--
From: Priom Rahman on
Sorry for the confusion, my apologies.

m=M';m=m(:)'; --> took 0.19 seconds for 8.18 million data cells

m =reshape(M.',1,[]); --> took 0.24 seconds for same data.

Thanks for all your help.