finding the maximum value table A for values in table B bellow benchmark
Afficher commentaires plus anciens
So, here's the situation: I have three tables: A = [50 100 30 4]; B = [100 150 90 50]; C = [50 100 150];
Value in C are benchmarks and we need a table that gives for each value of C, the maximum value in A such that all values in B are bellow/equal the benchmark. That is: D = [4 50 100]; In B only 50 is bellow/equal to 50 so 4 the máximum in A. But for 100, 100/90/50 are all bellow equal to 100 so 50 is the máximum in A.
I am trying with a loop but it's not working. Thanks a lot.
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Logical dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!