How to find the corresponding value?

Hello,
a = [ 1 2 3 6 8 4 ]
b = [10 11 12 13 14 15]
maxa= max(a)
bb = 14;
in this case, I want to find bb which correspond to the maximum value of a.
(because 'max(a)' located in the fifth, so I want to indicate the fifth value of the 'b')
how to do it?

 Accepted Answer

madhan ravi
madhan ravi on 12 Jun 2020
Edited: madhan ravi on 12 Jun 2020
[Max, Where] = max(a);
b(Where)

1 Comment

Thank you so much!
[ , ] is expressing the data sequence?

Sign in to comment.

More Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Products

Tags

Asked:

on 12 Jun 2020

Commented:

on 12 Jun 2020

Community Treasure Hunt

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

Start Hunting!