b = a[:,[1; 3; 5]] or if they are always going to be evenly spaced indexes like that, you can use a range:
b = a[:, 1:2:5]
On Tuesday, April 29, 2014 1:23:36 PM UTC-5, paul analyst wrote:
>
> a =rand(5,5)
> b=slicedim(a,2,1,3,5)
> ERROR: no method slicedim(Array{Float64,2}, Int64, Int64, Int64, Int64)
>
> how to choose from matrix a column 1,3,5 wihout while etc.?
> Paul
>
