<!--
{
  "availability" : [
    "iOS: 15.0.0 - 17.0.0",
    "iPadOS: 15.0.0 - 17.0.0",
    "macCatalyst: 15.0.0 - 17.0.0",
    "macOS: 10.14.0 - 14.0.0",
    "tvOS: 16.0.0 - 17.0.0",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CreateML",
  "identifier" : "/documentation/CreateML/MLClassifierMetrics/precisionRecall",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Create ML"
    ],
    "preciseIdentifier" : "s:8CreateML19MLClassifierMetricsV15precisionRecallAA11MLDataTableVvp"
  },
  "title" : "precisionRecall"
}
-->

# precisionRecall

A data table listing the precision and recall percentages for each class.

```
var precisionRecall: MLDataTable { get }
```

## Discussion

Precision and recall are metrics calculated for each class. Together they describe the tradeoff between
misapplying a label too liberally and missing examples of that label.

Precision describes how effective the model was at applying a label only when appropriate for a given category
(few false positives).

Recall describes how effective the model was at finding all the relevant examples of a category (few false
negatives).

![](images/com.apple.createml/MLClassifierMetrics-precisionRecall-1@2x.png)

The figure below shows how each example contributes to the precision and recall percentages for the category
“Elephant”.

![A table of actual and predicted labels for the Elephant category.](images/com.apple.createml/MLClassifierMetrics-precisionRecall-2@2x.png)

“Elephant” appears as the true or correct label only once, but it’s predicted twice. This second prediction is
an error in precision. Precision and recall can give you a much better idea of how your model is making
mistakes than [`classificationError`](/documentation/CreateML/MLClassifierMetrics/classificationError).

To determine what other categories “Elephant” examples may have been labeled with, see the
[`confusion`](/documentation/CreateML/MLClassifierMetrics/confusion) property.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)