# Statistics Functions

## Aggregate Functions

The following functions are used as aggregate in SQL Server's T-SQL the same way as the "Count", "Sum" and other aggregate functions are used. For instance, using the sql "Select dbo.Kurtosis(Price) from Orders" will provide the Kurtosis value for the entire content of the Price column for the Orders table.

Function |
Parameters |
Description |

Correlation | Double X Double Y |
Pearson product-moment correlation coefficient (sometimes referred to as the PPMCC or PCC, or Pearson's r, and is typically denoted by r) is a measure of the correlation (linear dependence) between two variables X and Y, giving a value between +1 and −1 inclusive. It is widely used in the sciences as a measure of the strength of linear dependence between two variables. More Information. |

Kurtosis | Double X | Kurtosis (from the Greek word κυρτός, kyrtos or kurtos, meaning bulging) is any measure of the "peakedness" of the probability distribution of a real-valued random variable. More Information. |

Median | Double X | The numerical value separating the higher half of a sample, a population, or a probability distribution, from the lower half. More Information. |

Percentile |
Double X |
The Percentile has three parameters: Option for Method: |

Skewness |
Double X |
Skewness is a measure of the asymmetry of the probability distribution of a real-valued random variable. The skewness value can be positive or negative, or even undefined. Qualitatively, a negative skew indicates that the tail on the left side of the probability density function is longer than the right side and the bulk of the values (possibly including the median) lie to the right of the mean. A positive skew indicates that the tail on the right side is longer than the left side and the bulk of the values lie to the left of the mean. A zero value indicates that the values are relatively evenly distributed on both sides of the mean, typically but not necessarily implying a symmetric distribution. |