>> x=linspace(0,2*pi,200); >> y=sin(x); >> figure;plot(x,y,'r-') >> set(gca,'xaxislocation','top') >> axis tight