%% Translate Square
% Create a square, then translate the square to the right by two units, and up by one unit. Plot both squares.

polyin = polyshape([0 0 1 1],[1 0 0 1]);
polyout = translate(polyin,[2 1]);
plot([polyin polyout])
axis equal

% Copyright 2012 The MathWorks, Inc.