Corr
The Corr function calculates the Pearson correlation coefficient, also known as the bivariate correlation, of two numerical columns.
You can use the Corr function on BigQuery, PostgreSQL, Snowflake, and AlloyDB connections.
Syntax
Corr(number column 1, number column 2)
Function arguments:
- number column 1 (required) - A column of numbers representing the dependent data.
- number column 2 (required) - A column of numbers representing the independent data.
Example
A table of sales data lists quantity sold and list price of items purchased. You can use the Corr function in the Table Summary to understand the relationship between the price of an item and the amount of an item that's purchased.
Corr([Quantity], [Price])
With this negative correlation, we can see that as price increases, the quantity of purchased item decreases.