MATLAB: How to extract data from 2D graph

extract data

Hi,
I got 2D graph like attacment. how to extract the data from .jpg? i do convert it in .fig but i have error:
"No appropriate method, property, or field 'ZData' for class 'matlab.graphics.primitive.Image'.
Error in test123 (line 12)
z = dataObjs(1).ZData"
Thanks untitled.jpg

Best Answer

If you have .fig,,,you can get the handles of the figure and the handles have XData and YData.