<!--
{
  "availability" : [
    "iOS: 12.0.0 - 13.0.0",
    "iPadOS: 12.0.0 - 13.0.0",
    "macCatalyst: 13.1.0 - 13.1.0",
    "macOS: 13.0.0 -",
    "visionOS: 1.0.0 - 1.0.0",
    "watchOS: 5.0.0 - 6.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "HealthKit",
  "identifier" : "/documentation/HealthKit/HKStatisticsOptions/discreteMostRecent",
  "metadataVersion" : "0.1.0",
  "role" : "Type Property",
  "symbol" : {
    "kind" : "Type Property",
    "modules" : [
      "HealthKit"
    ],
    "preciseIdentifier" : "c:@E@HKStatisticsOptions@HKStatisticsOptionDiscreteMostRecent"
  },
  "title" : "discreteMostRecent"
}
-->

# discreteMostRecent

An option indicating that the system returns the most recent quantity from the matching samples.

```
static var discreteMostRecent: HKStatisticsOptions { get }
```

## See Also

[`mostRecentQuantity()`](/documentation/HealthKit/HKStatistics/mostRecentQuantity())

Returns the most recent value from all the samples that match the query.

[`mostRecentQuantity(for:)`](/documentation/HealthKit/HKStatistics/mostRecentQuantity(for:))

Returns the most recent value from all the samples that match the query and were created by the specified source.

[`mostRecentQuantityDateInterval()`](/documentation/HealthKit/HKStatistics/mostRecentQuantityDateInterval())

Returns the date interval of the most recent sample that matches the query.

[`mostRecentQuantityDateInterval(for:)`](/documentation/HealthKit/HKStatistics/mostRecentQuantityDateInterval(for:))

Returns the date interval of the most recent sample that matches the query and was created by the specified source.



---

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)