How to ignore domain values to match range values
조회 수: 1 (최근 30일)
이전 댓글 표시
I have this x/y values that does not have the same length. Since x label is the widest, I want to ignore some y values so that I can use them for later plotting.
I am proceding the following way:
c = [1,2,3];
t = [now :1: now + 6]
x = sin(t)
I am trying to generate a code that reads the first n values of x to match the n values of c.
Can you please help?
댓글 수: 2
Matt Fig
2012년 9월 6일
What do you mean, "x label is the widest"?
You mention n, but don't show n. Is n the length of c?
x(c) % returns the first 3 values of x.
채택된 답변
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Annotations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!