Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Amy Yeh
 
Posts: n/a
Default How do I nesting subtotal function within average function in Exc

A B
1 January
2 Clothing & Apparel 44,408
3 Shoes 23,693
4 Jewellery 6,068
5 Cosmetics 29,670
6 Women's Fashions 103,839 (Subtotal)
7
8 Clothing & Apparel 28,600
9 Shoes 21,280
10 Men's Fashions 49,880 (Subtotal)
11
12 TOTAL 153,719
13 Average (Need a Formula on cell: B13 for the two Department)
I am grateful to anyone who can find a Formula for the Excel Worksheet.
THANKS.

  #2   Report Post  
Tim C
 
Posts: n/a
Default

Amy,

SUBTOTAL can perform functions other than totalling, such as averaging, and
SUBTOTAL fucntions ignore other SUBTOTAL functions. The first number tells
SUBTOTAL which function to use; 9 for sum and 1 for average.

B6: =SUBTOTAL(9,B2:B5)
B10: =SUBTOTAL(9,B8:B9)
B12: =SUBTOTAL(9,B2:B10)
B13: =SUBTOTAL(1,B2:B10)

Tim C

"Amy Yeh" <Amy wrote:

A B
1 January
2 Clothing & Apparel 44,408
3 Shoes 23,693
4 Jewellery 6,068
5 Cosmetics 29,670
6 Women's Fashions 103,839 (Subtotal)
7
8 Clothing & Apparel 28,600
9 Shoes 21,280
10 Men's Fashions 49,880 (Subtotal)
11
12 TOTAL 153,719
13 Average (Need a Formula on cell: B13 for the two
Department)
I am grateful to anyone who can find a Formula for the Excel Worksheet.
THANKS.



  #3   Report Post  
Amy Yeh
 
Posts: n/a
Default

Tim,

Thanks for your solution. I had used your formula on cell: B13, and the
answer was 25,619.83. Then I used a calculator to find out the correct
answer, which is 76,859.5. 153,719 is the Total Sales of the two
Departments, so it should be divided by 2. Therefore, I'm still trying to
figure out the formula for cell: B13.

"Tim C" wrote:

Amy,

SUBTOTAL can perform functions other than totalling, such as averaging, and
SUBTOTAL fucntions ignore other SUBTOTAL functions. The first number tells
SUBTOTAL which function to use; 9 for sum and 1 for average.

B6: =SUBTOTAL(9,B2:B5)
B10: =SUBTOTAL(9,B8:B9)
B12: =SUBTOTAL(9,B2:B10)
B13: =SUBTOTAL(1,B2:B10)

Tim C

"Amy Yeh" <Amy wrote:

A B
1 January
2 Clothing & Apparel 44,408
3 Shoes 23,693
4 Jewellery 6,068
5 Cosmetics 29,670
6 Women's Fashions 103,839 (Subtotal)
7
8 Clothing & Apparel 28,600
9 Shoes 21,280
10 Men's Fashions 49,880 (Subtotal)
11
12 TOTAL 153,719
13 Average (Need a Formula on cell: B13 for the two
Department)
I am grateful to anyone who can find a Formula for the Excel Worksheet.
THANKS.




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
Using The Average Function if a cell has NA carl Excel Worksheet Functions 6 May 21st 23 08:46 PM
Subtotal function George Gee New Users to Excel 3 January 20th 05 09:37 PM
Average function with If Danny Excel Worksheet Functions 2 December 3rd 04 07:27 PM
Excel's Pivot Table & Subtotal function should have a median fie. Mary Excel Worksheet Functions 1 December 3rd 04 04:27 PM
Using Average function when number is zero Deb Excel Worksheet Functions 3 November 6th 04 02:01 AM


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