Search code examples
matlabaxes

How to present points on axes in Matlab


I have two vectors of the same length and I'd like to treat the first as X values and the second as Y values and present (x,y) points on a graph.

How do I do this simple thing in Matlab?

Thanks!!!


Solution

  • It seems that it is just plot(x, y) what you need.

    For example to plot 'dots' use plot(x, y, '.'). For more examples of markers to use, see the attached link.