I have the following for loop to plot vectors from a M by 3 matrix of points, known as A
plot3([A(i,1) A(i+512,1)],[A(i,2) A(i+512,2)],[A(i,3) A(i+512,3)],'-','MarkerSize',10)
such that each point is connected to the one 512 points after it. (sets of 512 points form 2D cross sections, and I'm connecting each cross section to the next)
However as length(A) in my dataset is around 20e3, the plot takes a while to generate, and the performance is poor when rotating.
Is there such a way to plot this in a more efficient manner using data concatenation or other methods?