I have the following code
y=randn(50,50); x=randn(50,50);z=randn(50,50);surf(y,x,z);set(gca,'xlim',[0 2],'ylim',[0 2]);
Hence I only wish to show the surface between 0 and 2 on the x and y axis.
however, xlim ylim do not seem to work as per normal here. The data is shown overhanging the axis and doesnt look neat and tidy.
what have i done wrong? thank you
Best Answer