Thanks in advance for the help.
I have a series of coordinates in latitude, longitude, and depth (respectively called lat, long, and depth) and associated at each one of these points P(lat,long,depth) I have a value. The values for each of these points in contained in a 3d matrix called misfit(lat,long,depth). The idea is to make several imagesc (or contourf) plots to at varying depths to get an idea of my results and to have on each plot a point marking the minimum of the misfit (the matrix mentioned above). I contain the value and the coordinates of the minimum misfit (in that respective order) in the variable mini.
The problem is that when I do: figure; hold on imagesc(lat, long, misfit(:,:,mini(4))); plot(lat(mini(2)), long(mini(3)), 'ok', 'markersize', 15, 'markerfacecolor', 'k'); hold off
I have a surface that's minimum does not correspond at all to the point I plotted. When I go to the data cursor and go to the location of mini, it gives me back a value that is not at all the minimum value I want.
What am I missing here?
Best Answer