PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Calculating the variance
StatVariance (Example)
Calculating the variance
The following code is used to calculate the variance of the elements in row 3 of a matrix.
We assume that the matrix is already created and initialized.
// -- Click code on BTN_Variance
// Declare the variables
ResVariance is real
// Variance of elements in row 3
ResVariance = StatVariance("MyMatrix", 3, False)
// Error while calculating the variance?
IF StatError() = 0 THEN
// Display the variance
Info("The variance is: " + ResVariance)
ELSE
// Display the error message
Error(ErrorInfo(errMessage))
END
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment