Statistics function incorrectly computing median

Vercelli ororo at email.it
Sun Jan 6 08:40:06 CST 2008


----- Original Message ----- 
From: "Ben Abbott" <bpabbott at mac.com>
To: "Vercelli" <ororo at email.it>
Sent: Sunday, January 06, 2008 11:31 AM
Subject: Re: Statistics function incorrectly computing median


>
> On Jan 6, 2008, at 6:21 PM, Vercelli wrote:
>
>> I think that's not a bug, just an incoherence. The 2 functions 
>> (statistics and median) use two different definitions of median,  which 
>> are both used in statistic books.
>>
>> Luca
>
>
> f you don't mind can you (someone else?) answer this question for me?
>
> What would the 1st quartile, median and 3rd quartile be for a  population 
> of [0, 1, 2, 3, 4, 5]?
>
> My first impression would be 1.25, 2.5, and 3.75.
>
> However, the CDF for those values is [1/6, 2/6, 3/6, 4/6, 5/6, 6/6]. 
> Which implies the answer is 0.5, 2.0, and 3.5.
>
> Which is it? ... do you imply that *both* are correct, or something  else?
>
> What about quantiles approaching zero or unity?
>
> Ben
>
>

My first impression would be: [1,2,4] (as 'statistics' says)
If you have a finite population, it's quite useless consider values 
/different/ from the original ones. You should just consider the index of 
the elements.
Anyway, if one allows also different values, I don't know which is the right 
answer.

Luca



 
 
 --
 Email.it, the professional e-mail, gratis per te: http://www.email.it/f
 
 Sponsor:
 Cioccolato Venchi: promozione sul cioccolato da ordinare online
* 
* 
 Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=7107&d=6-1


More information about the Bug-octave mailing list