Extract data tips values from a plot in app designer
조회 수: 13 (최근 30일)
이전 댓글 표시
I want to add the X and Y values of data tips to a matrix. How can I do it?
As an example below, I want to create a 3x2 matrix from the data tip X and Y values
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1460962/image.png)
댓글 수: 0
채택된 답변
Florian Bidaud
2023년 8월 21일
p = plot([0:5],[1:6])
for i = 1:6
datatipsX(i) = p.Children(i).X;
datatipsY(i) = p.Children(i).Y;
end
댓글 수: 10
Florian Bidaud
2023년 8월 22일
Nice !
In the live script, you can't.
Otherwise, you should be able to do that with ax.Children.Children
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Graphics Object Programming에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!