How do I read a large list of X,Y co-ordinates from Notepad and plot a graph in Matlab ?
조회 수: 4 (최근 30일)
이전 댓글 표시
Hello all, I have a large list of points (about 16,000) in Notepad with X and Y co-ordinates. I want to read the list and plot different graphs on the same X and Y axes (i.e. the X axis is the same). How can I read the list in Matlab and plot the graphs based, with different colours ?
Thank You
댓글 수: 0
답변 (1개)
Azzi Abdelmalek
2014년 4월 17일
data=dlmread('yourfile.txt');
x=data(:,1);
y=data(:,2);
plot(x,y)
댓글 수: 1
Stelios Fanourakis
2018년 5월 2일
@Azzi That's nice. But what happens if txt files contains fractional numbers, negative integers or zeros. I cannot use I(x,y), where I is my image to imshow my image with x,y values as coordinators
참고 항목
카테고리
Help Center 및 File Exchange에서 Annotations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!