Arguments
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
| summary | StatsSummary2D | - | ✔ | The statistical aggregate produced by a stats_agg call |
| method | TEXT | sample | - | The method used for calculating the covariance. The two options are population and sample, which can be abbreviated to pop or samp |
Returns
| Column | Type | Description |
|---|---|---|
| covariance | DOUBLE PRECISION | The covariance of the least-squares fit line |
Samples
Calculate the covariance of independent variabley and dependent variable x for each 15-minute time bucket: