MATLAB: Placing Markers at Every Tenth Data Point and creating Label

label;markerMATLABplot

I understand that in order to place markers at every tenth data point I have to plot the data twice, e.g.,
x1 = 0:pi/100:2*pi;
x2 = 0:pi/10:2*pi;
plot(x1,sin(x1),'r:',x2,sin(x2),'r+')
But how do I create a label that would display both?
Thank you!

Best Answer

If by label you mean a legend entry, I'd add a dummy line to use for labeling
x = 0:pi/100:2*pi;
y = sin(x);
h = plot(x, y, ':r', x(1:10:end), y(1:10:end), 'r+', NaN, NaN, ':r+');
legend(h(3), 'my label');