slope()

Calculates the slope of the X/Y linear regression line by group. It eliminates expression pairs where either expression in the pair is NULL or not numeric.

Syntax

slope(EXPR_X, EXPR_Y)
Required Parameters
EXPR_X
Numeric expression to calculate the slope of the linear regression line.
EXPR_Y
Second numeric expression to calculate the slope of the linear regression line.