Quantile (Teradata Database) - Teradata Warehouse Miner

Teradata® Warehouse Miner™ User Guide - Volume 2ADS Generation

Product
Teradata Warehouse Miner
Release Number
5.4.6
Published
November 2018
Language
English (United States)
Last Update
2018-12-07
dita:mapPath
gxn1538171534877.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-2301
Product Category
Software

This function is only available when connected to a Teradata database.

Given a sort expression list and the number of quantile partitions, this Ordered Analytical function derives a new column giving the quantile partition that each row belongs to based on the sort expression list and the requested number of quantile partitions. When one or more Partition Columns are specified, the quantile partitions are computed separately over the rows in each partition. Rows options are not available with the Quantile function. Although there is a non-standard Teradata specific command QUANTILE, the function is implemented in Variable Creation using the standard RANK and COUNT functions.

A Teradata Warehouse Miner enhancement to the Quantile function is offered to optionally request that NULL values in any element of the sort expression list cause the row to be excluded in the ranking process. When dragging a Quantile function into a variable, the following tree element is created.

Variable Creation > Input > Variables: SQL Elements pane - Logical > Quantile

Sort expressions can be built up in the Sort Expressions folder, and Partition Columns can be built up in that folder. The enhancement to the Quantile function to optionally request that NULL values in any element of the sort expression list cause the row to be excluded in the ranking process, as well as the option to set the number of partitions, are both enabled through the Properties panel. Double-click on Quantile, or highlight it and click Properties.

Variable Creation > Input > Variables: SQL Elements pane - Logical > Quantile Properties

The default number of Partitions is 0, but can be changed here. Additionally, the default is to Include null values in the analysis, but that can be disabled here.