Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,670
Default How to determine the value?

Referring to the post in General Question

Does anyone know on how to determine the value in following case?

In cell A1 = 10 In cell B1 = 12
In cell A2 = 15 In cell B2 = 17
In cell A3 = 20 In cell B3 = 23

I would like to determine which pair [A & B] will be the minimum difference,
let take the abs of the difference in order to avoid negvative results. In
this case, abs(12-10) = 2 and abs(17-15) = 2, there are 2 pairs of value to
meet the minimum difference between A & B columns. Then I would like to
determine the minimum median value from those pairs, in this case (12+10) =
11, then the 11 will display in cell C1. Does anyone have any suggestion on
how to do this calculation in excel?
Thank you in advance
Eric Choi
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default How to determine the value?

Try this:

Entered as an array using the key combination of CTRL,SHIFT,ENTER (not just
ENTER):

=MIN(IF(ABS(A1:A3-B1:B3)=MIN(ABS(A1:A3-B1:B3)),SUBTOTAL(1,OFFSET(A1:B3,ROW(A1:B3)-1,,1,2))))

Biff

"Eric" wrote in message
...
Referring to the post in General Question

Does anyone know on how to determine the value in following case?

In cell A1 = 10 In cell B1 = 12
In cell A2 = 15 In cell B2 = 17
In cell A3 = 20 In cell B3 = 23

I would like to determine which pair [A & B] will be the minimum
difference,
let take the abs of the difference in order to avoid negvative results.
In
this case, abs(12-10) = 2 and abs(17-15) = 2, there are 2 pairs of value
to
meet the minimum difference between A & B columns. Then I would like to
determine the minimum median value from those pairs, in this case (12+10)
=
11, then the 11 will display in cell C1. Does anyone have any suggestion
on
how to do this calculation in excel?
Thank you in advance
Eric Choi



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to determine the value? Eric Excel Discussion (Misc queries) 1 February 13th 07 04:20 AM
How to determine the value? Eric Excel Discussion (Misc queries) 0 February 13th 07 03:26 AM
How to determine the first two carachters in a name hellZg8 Excel Discussion (Misc queries) 6 April 17th 06 12:56 PM
How can I determine the components of a sum? nealmjr Excel Discussion (Misc queries) 1 March 22nd 06 05:41 PM
How to Determine 1st, 2nd & 3rd for a PWD Pete n PWD Land Excel Discussion (Misc queries) 3 February 17th 05 09:25 PM


All times are GMT +1. The time now is 11:54 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"