What do you want to achieve - shuffling along a dimension (i.e. shuffling
rows or columns), or just shuffling all the numbers?
For the latter, it can be achieved pretty easily by reshaping to a vector
and back. This has the added benefit that it generalizes well to arbitrary
dimensions:
*shuffle!(vec(u))*
*will do what you want if **inlace shuffling is ok. Otherwise simply make a
copy before.*
Am Donnerstag, 24. März 2016 14:09:36 UTC+1 schrieb Arundhyoti Sarkar:
>
>
>
> Is there a way to shuffle matrix in julia like we do in matlab?
> I know shuffle(v) shuffles the vector