ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   =IF(AND Function (https://www.excelbanter.com/excel-worksheet-functions/116197-%3Dif-function.html)

[email protected]

=IF(AND Function
 
I am using the LOOKUP function in conjunction with the
IF(AND function. =IF(AND(B3="M",B4="R",LOOKUP(B1,C3:C6,D3:D6))
Would yield 20.3 for age 40. I am not sure how to test for all
variables (M, F, R,L) and select the correct value for any combination
(M-R, M-L,F-R,F-L)

Thanks for any help.


Example: B C D
E F

1 Age: 40 Male 2 Right Left
3 Sex: M/F (from pulldown list) 20 22.7 20
21.4
4 Domininance: R/L (from pulldown list) 30 21.9 30
20.5
5 40
20.3 40 19.6
6 50
19.7 50 18.3
7
8 Female
9 Right Left
10 20
18.4 20 17.7
11 30
19.6 30 18.6
12 40
17.4 40 16.8
13 50
16.9 50 15.2
14
15
16
17
18



Robert

Bob Phillips

=IF(AND Function
 
Create a table of all combinations and all results and then lookup B3&B4 in
that table.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

wrote in message
...
I am using the LOOKUP function in conjunction with the
IF(AND function. =IF(AND(B3="M",B4="R",LOOKUP(B1,C3:C6,D3:D6))
Would yield 20.3 for age 40. I am not sure how to test for all
variables (M, F, R,L) and select the correct value for any combination
(M-R, M-L,F-R,F-L)

Thanks for any help.


Example: B C D
E F

1 Age: 40 Male 2 Right Left
3 Sex: M/F (from pulldown list) 20 22.7 20
21.4
4 Domininance: R/L (from pulldown list) 30 21.9 30
20.5
5 40
20.3 40 19.6
6 50
19.7 50 18.3
7
8 Female
9 Right Left
10 20
18.4 20 17.7
11 30
19.6 30 18.6
12 40
17.4 40 16.8
13 50
16.9 50 15.2
14
15
16
17
18



Robert





All times are GMT +1. The time now is 05:17 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com