STEYX - script function

STEYX() returns the aggregated standard error of the predicted y-value for each x-value in the regression for a series of coordinates represented by paired numbers in x-expression and y-expression iterated over a number of records as defined by a group by clause.

Syntax:  

STEYX (y-value, x-value)

Return data type: numeric

Arguments:  

Argument Description
y_value The expression or field containing the range of y-values to be measured.
x_value The expression or field containing the range of x-values to be measured.

Limitations:  

Text values, NULL values and missing values in any or both pieces of a data-pair result in the entire data-pair being disregarded.

Examples and results:  

Add the example script to your document and run it. Then add, at least, the fields listed in the results column to a sheet in your document to see the result.

Example Result

Trend:

Load *, 1 as Grp;

LOAD * inline [

Month|KnownY|KnownX

Jan|2|6

Feb|3|5

Mar|9|11

Apr|6|7

May|8|5

Jun|7|4

Jul|5|5

Aug|10|8

Sep|9|10

Oct|12|14

Nov|15|17

Dec|14|16

] (delimiter is '|');

 

STEYX1:

LOAD Grp,

STEYX(KnownY, KnownX) as MySTEYX

Resident Trend Group By Grp;

In a table with the dimension MySTEYX, the result of the STEYX() calculation in the load script is 2.0714764.