---
title: "computeVariance(of:)"
framework: evaluations
role: symbol
role_heading: Instance Method
path: "evaluations/metricsaggregator/computevariance(of:)"
---

# computeVariance(of:)

Computes the variance of a metric and adds it to the aggregated results.

## Declaration

```swift
mutating func computeVariance(of metric: Metric)
```

## Parameters

- `metric`: The metric to aggregate.

## See Also

### Computing variability

- [computeStandardDeviation(of:)](evaluations/metricsaggregator/computestandarddeviation(of:).md)
