compare using if and or condition
Ältere Kommentare anzeigen
Hi,
I have attached a sample excel dataset. In the excel sheet there are two individual sheets 'T_a' and 'T_b'. I want to have a condition which compares the fifth columns of the sheets (Flow_a in sheet T_a and Flow_b in sheet T_b). If the Flow_b is greater than Flow_a ''OR'' if the Flow_a is gretaer than Flow_b by just 5%, then the new variable AE_compared would fill the respective cell with the value in AE_b from sheet T_b, else fill with the value from respective cell in AE_a from sheet T_a.
Thanks!!!!!
2 Kommentare
Geoff Hayes
am 17 Jun. 2019
Please show some of the code that you have written already. Are you able to open and read from the Excel file? Are you comparing each element of the two columns to get a result of whether one is greater than the other (by 5%)?
MatLab Code N
am 17 Jun. 2019
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Loops and Conditional Statements finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!