MATLAB: How to plot a series of points onto an image

.jpgfigureimagepictureplotplotting

I have an image file called 'bottle.jpg' and x and y values in the form of x=[# # #] and y=[# # #].
I can not figure out how to plot the x and y values onto the image file in a figure so that the overlapped plot/image is the only thing shown.
Thanks.

Best Answer

yourImage = imread('bottle.jpg');
imshow(yourImage);
hold on;
plot(x, y, 'r*', 'LineWidth', 2, 'MarkerSize', 15);
title('Bottle wit coordinates on it', 'FontSize', 24);
Related Question