ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Return a given value if the value of a cell is in a given range (https://www.excelbanter.com/excel-worksheet-functions/220674-return-given-value-if-value-cell-given-range.html)

vlpckett

Return a given value if the value of a cell is in a given range
 
I have a large spreadsheet of information that I am trying to simplify by
creating a "group" column. I need to build a formula that will look at the
number value in another cell and return a letter value based upon where
number value falls in my predetermined range.

For example; The formula will be in cell B1. I want to look at the number
value in cell A1. If the value in A1 is 10-50, 80 or 81 I want "F" to appear
in B1. If the value in A1 is 60-69 I want "V" to appear in B1.

Mike H

Return a given value if the value of a cell is in a given range
 
Hi,

=IF(OR(AND(A1=10,A1<=50),AND(A1=80,A1<=81)),"F", IF(AND(A1=60,A1<=69),"V",""))

mind the line wrap it's all one line.

Mike

"vlpckett" wrote:

I have a large spreadsheet of information that I am trying to simplify by
creating a "group" column. I need to build a formula that will look at the
number value in another cell and return a letter value based upon where
number value falls in my predetermined range.

For example; The formula will be in cell B1. I want to look at the number
value in cell A1. If the value in A1 is 10-50, 80 or 81 I want "F" to appear
in B1. If the value in A1 is 60-69 I want "V" to appear in B1.


Shane Devenshire[_2_]

Return a given value if the value of a cell is in a given range
 
Hi,

What happens to values between 51-59, 71-79 and over 81 or under 10?

=If(OR(AND(A1=10,A1<=50),A1=80,A1=81),"F","V")

This assumes there are no values in the other ranges you did not address.

--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"vlpckett" wrote:

I have a large spreadsheet of information that I am trying to simplify by
creating a "group" column. I need to build a formula that will look at the
number value in another cell and return a letter value based upon where
number value falls in my predetermined range.

For example; The formula will be in cell B1. I want to look at the number
value in cell A1. If the value in A1 is 10-50, 80 or 81 I want "F" to appear
in B1. If the value in A1 is 60-69 I want "V" to appear in B1.



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

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