DIPlib Documentation - ©1995-2009 Quantitative Imaging Group, Delft University of Technology.

# CumulativeSum

statistics function

## SYNOPSIS

`#include "dip_math.h"`

dip_Error dip_CumulativeSum ( in, mask, out, ps )

## DATA TYPES

binary, integer, float, complex

## FUNCTION

Calculates the cumulative sum of the pixel values over all those dimensions which are specified by `ps`, i.e.:

`out(x,y)=sum_i=0:x,j=0:y in(i,j)` when ps specifies both x and y `out(x,y)=sum_j=0:y in(x,j)` when ps specifies only y

## ARGUMENTS

Data type | Name | Description
`dip_Image` | `in` | Input
`dip_Image` | `mask (0)` | Mask
`dip_Image` | `out` | Output
`dip_BooleanArray` | `ps (0)` | Dimensions to project

## SEE ALSO

From images to scalars

`Mean`, `Variance`, `StandardDeviation`, `MeanModulus`, `SumModulus`, `MeanSquareModulus`, `Maximum`, `Minimum`, `Median`, `Percentile`

DIPlib on-line documentation | Function reference | Global function index