How to fit a curve into contour plot?
15 views (last 30 days)
John D'Errico on 19 Apr 2022
Edited: John D'Errico on 19 Apr 2022
Sometimes it is easier to just draw the curve yourself. I say this because the curve you drew might not have been the curve I would have chosen. I might have chosen something that goes more through the middle of the contour lines. And that means that your judgement about where you want the curve to be is most important.
Having said that, I would also point out that the AXIS scaling can be a significant factor in all of this. For example, consider the following set of contours:
To me, it clearly looks like the line I would draw here, using the same logic I think you used, that line would be vertical. Right?
In this second contour plot, the line drawn would absolutely be horizontal, correct?
I drew in lines where I think you would draw them in each case.
But, what if I told you the only difference between those two contour plots was the axis scaling?
[X,Y] = meshgrid(-100:100);
All I did then was to carefully change the axis scaling, making the same set of PERFECTLY circular contours, now look like they were pointing in one direction or another.
Look carefully at the axes on the two plots.
So are you still ABSOLUTELY positive where that line belongs? If you are, then just draw it by hand. But I would still be asking if you really do know where that curve belongs?