SecreC 2 language  2.8.0 (2023.09)
Language and standard library reference
Functions

Functions

template<domain D>
D float32 variance (D int32[[1]] data)
 
template<domain D>
D float64 variance (D int64[[1]] data)
 
template<domain D>
D float32 variance (D float32[[1]] data)
 
template<domain D>
D float64 variance (D float64[[1]] data)
 

Detailed Description

Find the variance of a vector.

Note
D - any protection domain
Supported types - int32 / int64 / float32 / float64
Parameters
data- input vector (the function may overflow if the input is too big)
Returns
returns the variance of the input vector
Leakage
None

Function Documentation

◆ variance() [1/4]

D float32 variance ( D float32[[1]]  data)

◆ variance() [2/4]

D float64 variance ( D float64[[1]]  data)

◆ variance() [3/4]

D float32 variance ( D int32[[1]]  data)

◆ variance() [4/4]

D float64 variance ( D int64[[1]]  data)