I am trying to graph a contour graph with a two dimentional matrix, v. v contains velocity data, y-index represents depth, x-index is mapped to a 1d-vector containing latitude info, lat.
when I graph contour(v), the x-axis is index, but I wish to show the latitude (also scale accordingly), I tried contour(lat,v) but it just shows me a blank graph, how should I graph it?
Without having an example dataset, it’s hard to say for sure… but I suspect that what you need to do is use the
contour(X,Y,Z)form ofcontour. If you want to specify one axis, you need to specify both. In your case, it would be:If you’re happy using the y-index rather than an actual depth vector, you can do