Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 28
Default Finding a close match

I have four time values in a row. The first value is a specific chosen time
value. The next three are demonstrated times. I need to find the closest
match of the three demonstrated times to the first column. Any help?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,268
Default Finding a close match

One way


=INDEX(B1:D1,MATCH(MIN(IF(ABS(B1:D1-A1)=MIN(ABS(B1:D1-A1)),B1:D1)),B1:D1,0))


entered with ctrl + shift & enter

where B1:D1 are the 4 values and A1 the chosen value



--


Regards,


Peo Sjoblom





"mailrail" wrote in message
...
I have four time values in a row. The first value is a specific chosen time
value. The next three are demonstrated times. I need to find the closest
match of the three demonstrated times to the first column. Any help?



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,268
Default Finding a close match

Meant where B1:D1 are the 3 demonstrated values


--


Regards,


Peo Sjoblom



"Peo Sjoblom" wrote in message
...
One way


=INDEX(B1:D1,MATCH(MIN(IF(ABS(B1:D1-A1)=MIN(ABS(B1:D1-A1)),B1:D1)),B1:D1,0))


entered with ctrl + shift & enter

where B1:D1 are the 4 values and A1 the chosen value



--


Regards,


Peo Sjoblom





"mailrail" wrote in message
...
I have four time values in a row. The first value is a specific chosen
time
value. The next three are demonstrated times. I need to find the closest
match of the three demonstrated times to the first column. Any help?





  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,344
Default Finding a close match

Hi,

Here is another solution:

=INDEX(T,MATCH(MIN(ABS(T-A1)),ABS(T-A1),0))

I have named the range A2:A4, where your three demonstration times are, T.
You don't need to use the name, just substitute the address. A1 is the cell
containing the time you want to check.

This formula is an array, which means you must press Shift+Ctrl+Enter to
enter it.

Remember to format the cell to a time format.

--
Thanks,
Shane Devenshire


"mailrail" wrote:

I have four time values in a row. The first value is a specific chosen time
value. The next three are demonstrated times. I need to find the closest
match of the three demonstrated times to the first column. Any help?

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
need to return next match of table, only finding first match...HEL nwtf_vol[_2_] Excel Worksheet Functions 0 January 23rd 08 01:42 AM
Finding a match and pasting next to it Donna S Excel Discussion (Misc queries) 2 November 16th 06 07:34 PM
Finding a Text match Richard Excel Discussion (Misc queries) 0 August 22nd 06 05:41 PM
Finding Closest Match andyiain Excel Worksheet Functions 1 March 15th 06 07:24 PM
Finding a match Ken Excel Discussion (Misc queries) 4 March 18th 05 04:42 PM


All times are GMT +1. The time now is 10:28 AM.

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

About Us

"It's about Microsoft Excel"