% example of creating a graph based on user selected points

% create the vectors for the x and y coordinates and set initial point to 0
% this will always set the first coordinate to (0,0) and create the 
% variables if it is the first time the script is run, but should leave 
% other points entered intact
x_coord(1) = 0;
y_coord(1) = 0;

% prompt user for points
x_coord(end+1) = input('Please enter the x coordinate for the point: ');
y_coord(end+1) = input('Please enter the y coordinate for the point: ');

% add the point to the plot
plot(x_coord, y_coord, 'b-o');
hold on;

% display statement telling user to run the script again for more points
disp('Please run this script again to add more points.');