#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 6
Default Count function

I have a spredsheet with 10 codes and a database with a list of data with
three columns one is headed code, (same as the 10 codes), one headed Race and
one headed Gender. I am truing to count by race and by gender and by code.
For example, I am trying to count all of the Hispanics that are also males
that fit into clde 2.

--
Jerry Edge
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,346
Default Count function

Hi,

Your discription suggest that the quickest and most elegent solution might
be a pivot table.

If you want a non-pivot table solution in 2007 you could consider
=COUNTIFS(Race,"Hispanics",Gender,"Male")
is an example, where Race is the column containing race and Gender is the
range containing the gender. You can expand this to handle three criteria at
the same time if necessary.

In 2003 you will need something like
=SUMPROODUCT((Race="Hispancis")*(Gender="Female"))

--
If this helps, please click the Yes button

Cheers,
Shane Devenshire


"Jerry Edge" wrote:

I have a spredsheet with 10 codes and a database with a list of data with
three columns one is headed code, (same as the 10 codes), one headed Race and
one headed Gender. I am truing to count by race and by gender and by code.
For example, I am trying to count all of the Hispanics that are also males
that fit into clde 2.

--
Jerry Edge

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Count function

Hi,

Maybe this

=SUMPRODUCT((B2:B20="Hispanic")*(C2:C20="Male")*(A 2:A20=2))

In practice I'd use cell references

=SUMPRODUCT((B2:B20=D1)*(C2:C20=E1)*(A2:A20=F1))

Mike

"Jerry Edge" wrote:

I have a spredsheet with 10 codes and a database with a list of data with
three columns one is headed code, (same as the 10 codes), one headed Race and
one headed Gender. I am truing to count by race and by gender and by code.
For example, I am trying to count all of the Hispanics that are also males
that fit into clde 2.

--
Jerry Edge

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 6
Default Count function

i tried all of the suggestions but they did not work either. I have a chart
i am trying to complete with data from a different worksheet. Mu chart is on
one worksheet and the data is on another worksheet.

Here is what I put in the calculation line
=SUMPRODUCT((Data!C:C=B9)*(Data!D:D=Control!A4)*(D ata!E:E=Control!A9),0)

I get this symbol as an answer #NUM!

Jerry

--
Jerry Edge


"Mike H" wrote:

Hi,

Maybe this

=SUMPRODUCT((B2:B20="Hispanic")*(C2:C20="Male")*(A 2:A20=2))

In practice I'd use cell references

=SUMPRODUCT((B2:B20=D1)*(C2:C20=E1)*(A2:A20=F1))

Mike

"Jerry Edge" wrote:

I have a spredsheet with 10 codes and a database with a list of data with
three columns one is headed code, (same as the 10 codes), one headed Race and
one headed Gender. I am truing to count by race and by gender and by code.
For example, I am trying to count all of the Hispanics that are also males
that fit into clde 2.

--
Jerry Edge

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
row count function Daniel Charts and Charting in Excel 1 June 14th 07 01:40 PM
Count function L.T. Excel Discussion (Misc queries) 4 January 20th 07 03:40 AM
Count Function Portuga Excel Discussion (Misc queries) 1 May 31st 06 04:53 PM
Count Function Portuga Excel Discussion (Misc queries) 4 May 31st 06 02:08 PM
using the count function barklek Excel Discussion (Misc queries) 3 August 22nd 05 01:00 PM


All times are GMT +1. The time now is 01:44 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"