Skip site navigation (1) Skip section navigation (2)

Re: Median

From: Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu>
To: Jan Wieck <JanWieck(at)Yahoo(dot)com>
Cc: omid omoomi <oomoomi(at)hotmail(dot)com>, BKermani(at)illumina(dot)com, pgsql-sql(at)postgresql(dot)org
Subject: Re: Median
Date: 2000-07-19 02:12:35
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-sql
> Maybe someone else has an idea.

I implemented a different algorithm several years ago. It is an
O(log(N)) process (unlike most other techniques), and was borrowed from
the "Algorithms" book (it's at work; but it is the classic "yellow
jacket" book with Fortran code and the other volume with *really bad* C
code which looks like Fortran ;)

Anyway, once the bugs were fixed (and there were several :( and a better
endgame algorithm was coded, it was suitable for hypercube distributed
processing, where you just exchange a small amount of info between
iterations. And it involved simply *counting* how many values were above
and below an initial or updated guess, then iterating on a new guess.

afaik that wouldn't be suitable for the existing aggregate capabilities,
but multi-pass algorithms would be nice to be able to do.

                    - Thomas

In response to

  • Re: Median at 2000-07-18 19:35:42 from Jan Wieck

pgsql-sql by date

Next:From: Patrick CoulombeDate: 2000-07-19 02:15:16
Subject: out-subject : thanks
Previous:From: andrewDate: 2000-07-19 00:19:03
Subject: Re: using a self referencing table

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group