---
title: "init(_:)"
framework: createmlcomponents
role: symbol
role_heading: Initializer
path: "createmlcomponents/classificationmetrics/init(_:)"
---

# init(_:)

Creates classification metrics for a sequence of predicted and ground truth label pairs.

## Declaration

```swift
init(_ pairs: some Sequence<(predicted: Label, label: Label)>)
```

## Parameters

- `pairs`: A sequence of predicted and true label pairs.

## See Also

### Creating the distribution

- [init(_:_:)](createmlcomponents/classificationmetrics/init(_:_:).md)
- [init()](createmlcomponents/classificationmetrics/init().md)
- [init(_:labels:)](createmlcomponents/classificationmetrics/init(_:labels:).md)
- [init(predicted:groundTruth:labels:)](createmlcomponents/classificationmetrics/init(predicted:groundtruth:labels:).md)
