?
Solved

If and between-values in Numbers for iWork or in Excel.

Posted on 2011-03-18
4
Medium Priority
?
422 Views
Last Modified: 2012-05-11
Hi I have a question about how to do something in Numbers in iWork and or in Excel. I want to make a cell do this:

If x - Y = between 0-4 then return 100. If x - y = between 5-9 then return 50. If not any of those return 0.

Is it possible to so something like that in numbers or in Excel?
0
Comment
Question by:guidx
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 81

Assisted Solution

by:zorvek (Kevin Jones)
zorvek (Kevin Jones) earned 200 total points
ID: 35170417
=IF(AND(A1-B1>=0,A1-B1<=4),100,IF(AND(A1-B1>=5,A1-B1<=9),50,0))

Where A1 is x and B1 is y.

Kevin
0
 
LVL 3

Accepted Solution

by:
ssisworo earned 1600 total points
ID: 35170419
with formula :

 "IF(A12-B12 <= 4, 100, IF( A12-B12 <= 9, 50, 0))"


and here is screen shot :
 screen
0
 
LVL 81

Expert Comment

by:zorvek (Kevin Jones)
ID: 35170427
A simpler formula:

=CHOOSE(MIN(A1-B1,3),100,50,0)

Where A1 is x and B1 is y.

Kevin
0
 
LVL 43

Assisted Solution

by:Saqib Husain, Syed
Saqib Husain, Syed earned 200 total points
ID: 35173799
Kevin, I do not see how your simpler formula will give the desired result.

guidx, Here is my formula

=VLOOKUP(A1-B1,{0,100;5,50;10,0},2)

Saqib
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
When you see single cell contains number and text, and you have to get any date out of it seems like cracking our heads.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.

766 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question