Nevron .NET Vision
Chart for .NET / User's Guide / Data Manipulation / Functions / Statistical Functions / Sum

In This Topic
    In This Topic
    SUM(arg1 [; ByEveryN])
    The 'arg1' argument must be an array.
    ByEveryN is an optional argument - an integer constant, greater or equal to 1.
    Returns a scalar value, which is the sum of the elements in the array 'arg1'.
    If ByEveryN is supplied, then the function calculates the sum of every N successive elements and the result is an array.

    Calculates the sum of all the elements in the input array, or the sum of every N successive elements in the input array.

    Example 1:

    Expression: SUM( arg1 )

    arg1 11 7 3 5 6 1

    Result: 33

    Example 2:

    (sum by every 2 elements)

    Expression: SUM( arg1; 2 )

    arg1 11 7 3 5 6 1
    result 18 8 7
     Related Examples
    Windows Forms: All Examples\Data Manipulation\Functions\Statistical\Sum of Data Items