---
title: "heartbeatSeries(_:)"
framework: healthkit
role: symbol
role_heading: Type Method
path: "healthkit/hksamplepredicate/heartbeatseries(_:)"
---

# heartbeatSeries(_:)

Returns a sample predicate that matches heartbeat series samples.

## Declaration

```swift
static func heartbeatSeries(_ predicate: NSPredicate? = nil) -> HKSamplePredicate<HKHeartbeatSeriesSample>
```

## Parameters

- `predicate`: An optional predicate that further restricts the results that the query returns.

## Discussion

Discussion Use this method to create an HKSamplePredicate instance that you can use to query for HKHeartbeatSeriesSample objects.

## See Also

### Creating Sample Predicates

- [audiogram(_:)](healthkit/hksamplepredicate/audiogram(_:).md)
- [categorySample(type:predicate:)](healthkit/hksamplepredicate/categorysample(type:predicate:).md)
- [clinicalRecord(type:predicate:)](healthkit/hksamplepredicate/clinicalrecord(type:predicate:).md)
- [correlation(type:predicate:)](healthkit/hksamplepredicate/correlation(type:predicate:).md)
- [electrocardiogram(_:)](healthkit/hksamplepredicate/electrocardiogram(_:).md)
- [quantitySample(type:predicate:)](healthkit/hksamplepredicate/quantitysample(type:predicate:).md)
- [sample(type:predicate:)](healthkit/hksamplepredicate/sample(type:predicate:).md)
- [visionPrescription(_:)](healthkit/hksamplepredicate/visionprescription(_:).md)
- [workout(_:)](healthkit/hksamplepredicate/workout(_:).md)
- [workoutRoute(_:)](healthkit/hksamplepredicate/workoutroute(_:).md)
