cool - thanks! On 26. 9. 2014 14:19, martin van dinther wrote:
Hi,
maybe this helps:
CREATE AGGREGATE Rmedian(arg1 double) RETURNS double LANGUAGE R { quantile(arg1, 0.5) };
SELECT median(val), Rmedian(val) FROM (SELECT 1.0 as val UNION ALL SELECT 2.0) as virttable;
This returns: 1 for the median() and 1.5 for the Rmedian() set functions.
To use the: LANGUAGE R { quantile(arg1, 0.5) } functionality you will need to use: - the latest MonetDB developer built and - start the mserver5 with option: --set embedded_r=true
Regards, Martin van Dinther
On 22-09-14 08:58, Lefteris wrote:
To achieve happiness, you can create your own UDF!
Lefteris
On Mon, Sep 22, 2014 at 8:29 AM, Budulinku Dejmihrasku
mailto:budulinku.dejmihrasku@gmail.com> wrote: not happy but thanks for the explanation m.
On 22. 9. 2014 7:58, Niels Nes wrote:
The Median in MonetDB is mapped to Quantile(0.5) which doesn't have any mean of the middle values.
http://en.wikipedia.org/wiki/Quantile
Niels
_______________________________________________ users-list mailing list users-list@monetdb.org https://www.monetdb.org/mailman/listinfo/users-list