where are my data?
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Paul Rogers
el 14 de En. de 2020
Comentada: Star Strider
el 14 de En. de 2020
I plot a figure by using a function from a package.
Now I'd like to know the x and y values once I plot the curve.
Where are they stored
0 comentarios
Respuesta aceptada
Star Strider
el 14 de En. de 2020
Try this:
F = openfig('untitled.fig');
ax = gca;
lines = findobj(ax, 'Type','Line');
for k = 1:numel(lines)
x{k,:} = lines(k).XData;
y{k,:} = lines(k).YData;
end
The x- and y-data for each line are in their appropriate cell arrays.
4 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Creating, Deleting, and Querying Graphics Objects en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!