I've plot my spectrum with "plot (abs(wave));". I successfully got my Y max value with "maxY = max(abs(wave))". But now I want the X axis value that corresponds to my maximum Y value. Anybody can help? Thank you in advance!

 채택된 답변

Iain
Iain 2014년 9월 22일

1 개 추천

[maxY index] = max(abs(wave));
index is either the X value, or something you can use to get the x values, eg,
x = 1:54:23423
correspondingX = x(index);

댓글 수: 1

nevin
nevin 2014년 9월 24일
This was very helpful. Thank you so much my kind sir!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터 및 File Exchange에서 Line Plots에 대해 자세히 알아보기

질문:

2014년 9월 22일

댓글:

2014년 9월 24일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by