|
|
|
|
- Calculating the standard deviation
StatStandardDeviationP (Example)
Calculating the standard deviation The following code is used to calculate the standard deviation for the value of the elements in row 3. The value of the elements in this row represents the entire population. We assume that the matrix is already created and initialized. // -- Click code on BTN_StdDeviationP // Declare the variables ResStandardDeviationP is real // Standard deviation for the value of elements in row 3 ResStandardDeviationP = StatStandardDeviationP("MyMatrix", 3, False) // Display the result IF ResStandarDeviationP <> 0 THEN Info("The standard deviation is: " + ResStandardDeviationP) ELSE // Error while calculating the standard deviation? IF StatError() <> 0 THEN Info("The standard deviation is null") ELSE // Display the error message Error(ErrorInfo(errMessage)) END END
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|