Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 23
Default nested MATCH within Array formula?

I have a large table of data (incident reports) and I want to use an array
formula to give me a count of incidents where
- the month is January (months are in column A)
- the region is Nelson, Marlborough or Canterbury (regions are in col B)
- the body part is foot, knee or leg (body parts are in col C)

I have a named range called UpperSouth which contains Nelson, Marlborough
and Canterbury
and I have a named range called LowerLimb which contains leg, foot and knee

I can get a count of all incidents in UpperSouth area in January using the
array formula
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ B$2:$B$1000,UpperSouth,0)))

or I can get a count of all incidents in January involving lower limbs by
using
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ C$2:$C$1000,LowerLimb,0)))

but what I can't work out is how to nest my MATCHes so I can get a count of
incidents in January, in the UpperSouth area involving lower limbs.

Help!
Thanks
Katy
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default nested MATCH within Array formula?

Try this normally entered formula (not array entered):

=SUMPRODUCT(--(Data!$A$2:$A$1000="January"),--(ISNUMBER(MATCH(Data!$B$2:$B$1000,UpperSouth,0))),--(ISNUMBER(MATCH(Data!$C$2:$C$1000,LowerLimb,0))))


--
Biff
Microsoft Excel MVP


"katy" wrote in message
...
I have a large table of data (incident reports) and I want to use an array
formula to give me a count of incidents where
- the month is January (months are in column A)
- the region is Nelson, Marlborough or Canterbury (regions are in col B)
- the body part is foot, knee or leg (body parts are in col C)

I have a named range called UpperSouth which contains Nelson, Marlborough
and Canterbury
and I have a named range called LowerLimb which contains leg, foot and
knee

I can get a count of all incidents in UpperSouth area in January using the
array formula
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ B$2:$B$1000,UpperSouth,0)))

or I can get a count of all incidents in January involving lower limbs by
using
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ C$2:$C$1000,LowerLimb,0)))

but what I can't work out is how to nest my MATCHes so I can get a count
of
incidents in January, in the UpperSouth area involving lower limbs.

Help!
Thanks
Katy



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 23
Default nested MATCH within Array formula?

Great! that works a treat.
I assume the benefit of doing a sumproduct, rather than an array formula, is
that it's quicker and smaller (in terms of file size)?
And if I wanted to exclude one of the named ranges, for example if I want a
count of all incidents OUTSIDE the UpperSouth region, I would just replace
the ISNUMBER with ISNA in the relevant part of the formula?

Thank you so much for you help.
Katy

"T. Valko" wrote:

Try this normally entered formula (not array entered):

=SUMPRODUCT(--(Data!$A$2:$A$1000="January"),--(ISNUMBER(MATCH(Data!$B$2:$B$1000,UpperSouth,0))),--(ISNUMBER(MATCH(Data!$C$2:$C$1000,LowerLimb,0))))


--
Biff
Microsoft Excel MVP


"katy" wrote in message
...
I have a large table of data (incident reports) and I want to use an array
formula to give me a count of incidents where
- the month is January (months are in column A)
- the region is Nelson, Marlborough or Canterbury (regions are in col B)
- the body part is foot, knee or leg (body parts are in col C)

I have a named range called UpperSouth which contains Nelson, Marlborough
and Canterbury
and I have a named range called LowerLimb which contains leg, foot and
knee

I can get a count of all incidents in UpperSouth area in January using the
array formula
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ B$2:$B$1000,UpperSouth,0)))

or I can get a count of all incidents in January involving lower limbs by
using
=COUNT(IF(Data!$A$2:$A$1000="January",MATCH(Data!$ C$2:$C$1000,LowerLimb,0)))

but what I can't work out is how to nest my MATCHes so I can get a count
of
incidents in January, in the UpperSouth area involving lower limbs.

Help!
Thanks
Katy




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
Array formula with index + match Sena Excel Worksheet Functions 5 April 1st 07 06:06 AM
Array Formula Using Max Match Logic JR573PUTT Excel Discussion (Misc queries) 4 February 26th 06 05:09 AM
Index and Match Array formula Graham Haughs Excel Worksheet Functions 4 February 16th 06 01:51 AM
Array Match Formula [email protected] Excel Discussion (Misc queries) 1 March 5th 05 08:00 AM
Match / Vlookup within an Array formula Hari Prasadh Excel Discussion (Misc queries) 3 February 3rd 05 04:37 PM


All times are GMT +1. The time now is 07:15 AM.

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"