correlation(type:predicate:)
Returns a sample predicate that matches samples that contain correlated data.
Declaration
static func correlation(type correlationType: HKCorrelationType, predicate: NSPredicate? = nil) -> HKSamplePredicate<HKCorrelation>Parameters
- correlationType:
A type that matches samples that contain a set of subsamples.
- predicate:
An optional predicate that further restricts the results that the query returns.
Discussion
Use this method to create an HKSamplePredicate instance that you can use to query for HKCorrelation objects.