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


In Column A I have the ages of a random number of people. I need to
take the median of the top 25% of this list. First I sorted the list,
and now i need to run Median(A1:AX) Where X is the cell that equals 25%
of my total population. My problem is the population(and thus the
number of rows used) is constantly changing. How can I put in a value
for AX into this equation? Thanks in advance.
Karl


--
flyingmeatball
------------------------------------------------------------------------
flyingmeatball's Profile: http://www.excelforum.com/member.php...o&userid=37302
View this thread: http://www.excelforum.com/showthread...hreadid=572682

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,339
Default median function

try:

=MEDIAN(INDIRECT("A1:A"&INT(COUNTA(A:A)/4)))

This rounds down so that if there are 27 numbers, median is calculated as A1
to A6 ....should it be A1 to A7?

HTH

"flyingmeatball" wrote:


In Column A I have the ages of a random number of people. I need to
take the median of the top 25% of this list. First I sorted the list,
and now i need to run Median(A1:AX) Where X is the cell that equals 25%
of my total population. My problem is the population(and thus the
number of rows used) is constantly changing. How can I put in a value
for AX into this equation? Thanks in advance.
Karl


--
flyingmeatball
------------------------------------------------------------------------
flyingmeatball's Profile: http://www.excelforum.com/member.php...o&userid=37302
View this thread: http://www.excelforum.com/showthread...hreadid=572682


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

Let's say the ages are in A2:A26.

I'd use the following function

=MEDIAN(IF(A2:A26QUARTILE(A2:A26,3),A2:A26))

COMMIT using CTRL SHIFT ENTER and you should see {} around the whole thing.

I'd probably use a named range with an offset to determine the dynamic range
for A2:A26, but that's another whole conversation. Check here for
information on dynamic ranges

http://www.cpearson.com/excel/named.htm

"flyingmeatball" wrote:


In Column A I have the ages of a random number of people. I need to
take the median of the top 25% of this list. First I sorted the list,
and now i need to run Median(A1:AX) Where X is the cell that equals 25%
of my total population. My problem is the population(and thus the
number of rows used) is constantly changing. How can I put in a value
for AX into this equation? Thanks in advance.
Karl


--
flyingmeatball
------------------------------------------------------------------------
flyingmeatball's Profile: http://www.excelforum.com/member.php...o&userid=37302
View this thread: http://www.excelforum.com/showthread...hreadid=572682


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
Custom functions calculating time arguments Help Desperate Bill_De Excel Worksheet Functions 12 April 25th 06 02:22 AM
Date & Time mully New Users to Excel 4 May 23rd 05 11:56 AM
Conversion SVC Excel Worksheet Functions 9 February 28th 05 02:29 PM
Excel's Pivot Table & Subtotal function should have a median fie. Mary Excel Worksheet Functions 1 December 3rd 04 03:27 PM
HOW CAN I GET OFFICE 2003 EXCEL BASIC TO NEST FUNCTIONS LIKE EXCE. Robert AS Excel Worksheet Functions 4 December 2nd 04 10:49 AM


All times are GMT +1. The time now is 05:26 AM.

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"