Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 19
Default How to get =MIN() given flags?

Hi all,

Here is a breeze question for you guys!

I want to get a minimum number in Column B from the numbers whose flag in
Column A shows "Y".

<Scenario 1
A B
1 1
2 Y 5
3 Y 8
4 Y 12

The required function should show 5.

<Scenario 2
A B
1 1
2 Y 5
3 8
4 Y 12

The required function should show 5.

What is the array function to do the above?

Thanks in advance.

Tetsuya Oguma
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default How to get =MIN() given flags?

Assuming your data occupies A1:B4, enter this array* formula in C1:

=MIN(IF((A1:A4="Y"),B1:B4))

Adjust the ranges to suit.

*As this is an array formula, once you have typed it in (or
subsequently edit it) you need to use CTRL-SHIFT-ENTER (CSE) rather
than just ENTER. If you do this correctly then Excel will wrap the
formula in curly braces { } when viewed in the formula bar - you must
not type these yourself.

Hope this helps.

Pete

Tetsuya Oguma wrote:

Hi all,

Here is a breeze question for you guys!

I want to get a minimum number in Column B from the numbers whose flag in
Column A shows "Y".

<Scenario 1
A B
1 1
2 Y 5
3 Y 8
4 Y 12

The required function should show 5.

<Scenario 2
A B
1 1
2 Y 5
3 8
4 Y 12

The required function should show 5.

What is the array function to do the above?

Thanks in advance.

Tetsuya Oguma


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,726
Default How to get =MIN() given flags?

=MIN(IF(A1:A5="Y",B1:B5))

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.

--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"Tetsuya Oguma" wrote in message
...
Hi all,

Here is a breeze question for you guys!

I want to get a minimum number in Column B from the numbers whose flag in
Column A shows "Y".

<Scenario 1
A B
1 1
2 Y 5
3 Y 8
4 Y 12

The required function should show 5.

<Scenario 2
A B
1 1
2 Y 5
3 8
4 Y 12

The required function should show 5.

What is the array function to do the above?

Thanks in advance.

Tetsuya Oguma



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 740
Default How to get =MIN() given flags?

Hi Tetsuya ..are there any blank cells on column B without a number ?

"Tetsuya Oguma" wrote:

Hi all,

Here is a breeze question for you guys!

I want to get a minimum number in Column B from the numbers whose flag in
Column A shows "Y".

<Scenario 1
A B
1 1
2 Y 5
3 Y 8
4 Y 12

The required function should show 5.

<Scenario 2
A B
1 1
2 Y 5
3 8
4 Y 12

The required function should show 5.

What is the array function to do the above?

Thanks in advance.

Tetsuya Oguma

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
Is there a way to determine which cell the function =min() used? Justin Excel Worksheet Functions 6 October 16th 05 01:14 PM


All times are GMT +1. The time now is 08:34 PM.

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"