I have a function that creates two plots, I want to run that function in a for loop but have the plots updated with the new lines rather than create new plots. If I use hold on, then the two different types of plot will be on the same set of axis so I don't want that.
ax1 = nexttile;
p = [loc(i,1) loc(i,2); loc(i,1)-0.1*Cp(i)*normVect(i,1) loc(i,2)-0.1*Cp(i)*normVect(i,2)];
ax2 = nexttile;
so with this example code I would like the first plot to conitunally update ax1 on each itteration and the second to update ax2 for each itteration.