Julia: delete rows and columns from an array or matix
问题 How can I delete one or more rows and/or columns from an array? 回答1: Working with: julia> array = [1 2 3 4; 5 6 7 8; 9 10 11 12; 13 14 15 16] 4×4 Array{Int64,2}: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 To delete a single row (here row 2): julia> newarray = array[1:end .!= 2, :] 3×4 Array{Int64,2}: 1 2 3 4 9 10 11 12 13 14 15 16 To delete a single column (here column 3): julia> newarray = array[:, 1:end .!= 3] 4×3 Array{Int64,2}: 1 2 4 5 6 8 9 10 12 13 14 16 To delete a single row and a single