Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dr Happy
 
Posts: n/a
Default How do i analyse visible rows only in excel?

I have created a worksheet consisting of columns consisting of name, work
group ( a 2 digit alpha numeric), gender and then some numerical data. I want
to autofilter on work group and then perform analysis on only the visible
rows left. Obviously I only want 1 summary row at the bottom which will
change as I apply different criteria to the auto filter (by selecting
different work groups). I can get count functions to work with sub-total but
I need to use the countif function. Any clues?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Khaldoun
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi,

the first solution jumping to my mind would be one of the two: -
1- either you use advanced filter and copy data to a new sheet where you can
analyse it

or

2- better use Pivot Tables.

Will any of these do?

Khaldoun
Specialized Technologies
Saudi Arabia


--
Khldoun
Specialized Technologies
Saudi Arabia


"Dr Happy" wrote:

I have created a worksheet consisting of columns consisting of name, work
group ( a 2 digit alpha numeric), gender and then some numerical data. I want
to autofilter on work group and then perform analysis on only the visible
rows left. Obviously I only want 1 summary row at the bottom which will
change as I apply different criteria to the auto filter (by selecting
different work groups). I can get count functions to work with sub-total but
I need to use the countif function. Any clues?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Here is an example where B2:b20 is filtered, and a condition in A2:A20 is
tested

=SUMPRODUCT((SUBTOTAL(3,OFFSET($B$1,ROW($B$2:$B$20 )-ROW($B$1),,1)))*(C2:C20=
"a"))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Dr Happy" <Dr wrote in message
...
I have created a worksheet consisting of columns consisting of name, work
group ( a 2 digit alpha numeric), gender and then some numerical data. I

want
to autofilter on work group and then perform analysis on only the visible
rows left. Obviously I only want 1 summary row at the bottom which will
change as I apply different criteria to the auto filter (by selecting
different work groups). I can get count functions to work with sub-total

but
I need to use the countif function. Any clues?



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bernie Deitrick
 
Posts: n/a
Default How do i analyse visible rows only in excel?

You are either going not far enough, or too far. If you want to ue Filters and SUBTOTAL, then you
need to completely filter your data to get your count, along with your additional criteria from
COUNTIF - that is the equivalent of using COUNTIF. So apply another level or two of filtering.

Or don't use filters at all, and use pivot tables, hiding what you don't need.

Or - use horribly complicated SUMPRODUCT Formulas.

HTH,
Bernie
MS Excel MVP


"Dr Happy" <Dr wrote in message
...
I have created a worksheet consisting of columns consisting of name, work
group ( a 2 digit alpha numeric), gender and then some numerical data. I want
to autofilter on work group and then perform analysis on only the visible
rows left. Obviously I only want 1 summary row at the bottom which will
change as I apply different criteria to the auto filter (by selecting
different work groups). I can get count functions to work with sub-total but
I need to use the countif function. Any clues?



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi Roger,

Problem is that it does handle filtered rows, but not rows hidden by some
other method. I posted a solution that incorporated a UDF for that case a
few days ago, which also handles the filtered data. Might just use that as
my standard.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Roger Govier" wrote in message
...
Hi Bob

That's cool.
Never thought about using the Subtotal function inside Sumproduct like

that.

Regards

Roger Govier


Bob Phillips wrote:
Here is an example where B2:b20 is filtered, and a condition in A2:A20

is
tested


=SUMPRODUCT((SUBTOTAL(3,OFFSET($B$1,ROW($B$2:$B$20 )-ROW($B$1),,1)))*(C2:C20=
"a"))





  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi Roger,

My Excel of choice is still 2000 (£ being my driver :-( ), and that only
goes up to 11, so I didn't know that. Thanks, I have learned something.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Roger Govier" wrote in message
...
Hi Bob

It will handle rows hidden, as opposed to filtered, if you substitute 103

for 3

=SUMPRODUCT((SUBTOTAL(103,OFFSET($B$1,ROW($B$2:$B$ 20)-ROW($B$1),,1)))*(C2:C2
0="a"))

This is a feature that is present in Xl2003, and maybe in XL2002(??)

Regards

Roger Govier


Bob Phillips wrote:
Hi Roger,

Problem is that it does handle filtered rows, but not rows hidden by

some
other method. I posted a solution that incorporated a UDF for that case

a
few days ago, which also handles the filtered data. Might just use that

as
my standard.



  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Roger Govier
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi Bob

That's cool.
Never thought about using the Subtotal function inside Sumproduct like that.

Regards

Roger Govier


Bob Phillips wrote:
Here is an example where B2:b20 is filtered, and a condition in A2:A20 is
tested

=SUMPRODUCT((SUBTOTAL(3,OFFSET($B$1,ROW($B$2:$B$20 )-ROW($B$1),,1)))*(C2:C20=
"a"))

  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Roger Govier
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi Bob

It will handle rows hidden, as opposed to filtered, if you substitute 103 for 3
=SUMPRODUCT((SUBTOTAL(103,OFFSET($B$1,ROW($B$2:$B$ 20)-ROW($B$1),,1)))*(C2:C20="a"))

This is a feature that is present in Xl2003, and maybe in XL2002(??)

Regards

Roger Govier


Bob Phillips wrote:
Hi Roger,

Problem is that it does handle filtered rows, but not rows hidden by some
other method. I posted a solution that incorporated a UDF for that case a
few days ago, which also handles the filtered data. Might just use that as
my standard.

  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Roger Govier
 
Posts: n/a
Default How do i analyse visible rows only in excel?

Hi Bob
(£ being my driver :-( )

what other driver is there???
Waiting for Excel 12 perhaps!!

I just checked out XL2002 and it does not exist in that version.

Regards

Roger Govier


Bob Phillips wrote:
Hi Roger,

My Excel of choice is still 2000 (£ being my driver :-( ), and that only
goes up to 11, so I didn't know that. Thanks, I have learned something.

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
TRYING TO SET UP EXCEL SPREADSHEET ON MY COMPUTER MEGTOM New Users to Excel 5 October 27th 05 03:06 AM
Can I copy data from only the visible rows in Excel? Sarah Excel Discussion (Misc queries) 1 October 8th 05 09:23 PM
Updating rows - Excel Formula or Something Else? bevpike Excel Worksheet Functions 2 March 30th 05 05:52 AM
How do I import data into Excel that exceeds 70000 rows? Claudia Phelps Excel Discussion (Misc queries) 2 March 25th 05 11:33 PM
How do I remove blank rows in Excel? m28leics Excel Discussion (Misc queries) 2 November 29th 04 11:56 PM


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