quantile
Quantile aggregation function
Repository
tvondra/quantile
https://github.com/tvondra/quantile
Source
quantile-1.1.8.tar.gz
quantile-1.1.8.tar.gz
Overview
| Package | Version | Category | License | Language |
|---|---|---|---|---|
quantile | 1.1.8 | FUNC | BSD-2-Clause | C |
| ID | Extension | Bin | Lib | Load | Create | Trust | Reloc | Schema |
|---|---|---|---|---|---|---|---|---|
| 4610 | quantile | No | Yes | No | Yes | No | No | - |
| Related | ddsketch tdigest weighted_statistics lower_quantile topn count_distinct omnisketch datasketches hll |
|---|
Version
| Type | Repo | Version | PG Ver | Package | Deps |
|---|---|---|---|---|---|
| EXT | PIGSTY | 1.1.8 | 1817161514 | quantile | - |
| RPM | PIGSTY | 1.1.8 | 1817161514 | quantile_$v | - |
| DEB | PIGSTY | 1.1.8 | 1817161514 | postgresql-$v-quantile | - |
Build
You can build the RPM / DEB packages for quantile using pig build:
Install
You can install quantile directly. First, make sure the PGDG and PIGSTY repositories are added and enabled:
Install the extension using pig or apt/yum/dnf:
Install
pig
dnf
apt
Create Extension:
Usage
Provides aggregate functions to compute quantiles. Overloaded for int, bigint, double precision, and numeric.
Functions
| Function | Description |
|---|---|
quantile(value, quantile float) | Compute a single quantile (0 to 1) |
quantile(value, quantiles float[]) | Compute multiple quantiles at once, returns array |
Examples
Note: Since PostgreSQL 9.4, built-in percentile_cont and percentile_disc functions are available. Consider using those first and only use this extension if it provides measurably better performance for your workload.
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)