REGR_SYY
REGR_SYY(y, x)
Section titled “REGR_SYY(y, x)”- y: It’s the dependent variable represented usually as the response in the language of regression analysis. It’s a numerical input for which REGR_SYY computation is made. Null or non-numeric inputs result in null outputs.
- x: It’s the independent variable, also known as the predictor in regression analysis. This is also a numerical input which helps in the regression computations. Similar to y, null or non-numeric input values result in null outputs.
Example
Section titled “Example”SELECT REGR_SYY(score, hours_studied) AS regr_syyFROM student_scores;Output
Section titled “Output”REGR_SYY------------285.17955Explanation
Section titled “Explanation”The REGR_SYY function in Oracle performs a linear regression calculation and returns the sum of squares of the differences of the dependent variable. In this example, it calculates the sum of squares of the differences for ‘score’ for each ‘hours_studied’ in the ‘student_scores’ table.
REGR_SYY(Y, X)
Section titled “REGR_SYY(Y, X)”- y: This is the dependent variable in the regression equation. It is typically the variable we’re interested in predicting or understanding. Each value of Y corresponds to a value of X in the data set.
- x: This is the independent variable in the regression equation. It is the variable we use to predict or explain the variations in Y. Each value of X corresponds with a value of Y in the data set.
Example
Section titled “Example”SELECT REGR_SYY(column1, column2)FROM table;Output
Section titled “Output” regr_syy---------- 47.2Explanation
Section titled “Explanation”The REGR_SYY function in SQL is used to compute the sum of squares of the differences from the mean for column2. The value provided is the result of this computation on the provided dataset in the ‘table’.