Variance

4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next

version 3


Variance (series) Number

ParameterTypeDescription
seriesField or subfieldData for which to return the variance
Function resultNumberVariance of series

Description

Variance returns the variance for series. If series is an indexed field, the index is used to find the variance. You can only use a field with this function when printing a report.

Example

The following example is an object method for the variable var. The object method assigns the sum of squares for a data series to var:

   var:= Variance (Students]Grades)

The following method is called to print the records in the selection and to activate break processing:

   ALL RECORDS ([Students]) 
   ORDER BY ([Students];[Students]Class;>) 
   BREAK LEVEL (1) 
   ACCUMULATE ([Students]Grades) 
   OUTPUT FORM ([Students];"PrintForm") 
   PRINT SELECTION ([Students])

Note: The parameter to the BREAK LEVEL command should be equal to the number of breaks in your report. For more information about break processing, refer to the printing commands.

See Also

Average, Std deviation, Sum, Sum squares.


4D - Documentation   Français   English   German   4th Dimension 2004, Command Theme List   4th Dimension 2004, Command Alphabetical List   4th Dimension 2004, Constant Theme List   Back   Previous   Next