This is a forum for 3rd party programmers with Apple engineers assisting on the tough questions. So to maximize your learning and the developer community to help you, you'll need to do some basic web searches yourself including searches on this forum:
Apple provides the Apple Watch which does provide some aspects of heart rate variability and that information is exposed via a HealthKit API:
IBI, sdnn, rmssd?
heartRateVariabilitySDNN
A quantity sample type that measures the standard deviation of heartbeat intervals.
https://developer.apple.com/documentation/healthkit/hkquantitytypeidentifier/2881127-heartratevariabilitysdnnretrieve this data from your cloud database
HealthKit APIs are device-based APIs as that data is stored on device in the iOS Health database. Some types of health data can be captured directly from the Apple Watch but in general all data should eventually wind up in the iOS Health database. So, if a user grants a 3rd party app (and hopefully you'll create a great research app) the app can extract that data. Users can view HRV data in the iOS Health app. The App Store does list many HRV apps.
Apple does have strict requirements for both app developers and researchers when handling user health data and Apple does support the research community:
https://developer.apple.com/carekit/And there is some published research about this very subject such as the 2018 "Validation of the Apple Watch for Heart Rate Variability Measurements during Relax and Mental Stress in Healthy Subjects" with the standard "I'm just referencing, I'm not endorsing" disclaimer.
make sure that the PPG sensor is operating constantly
In general, this is out of the app developer's hands as you cannot force the device to report its data faster, or force the HealthKit API to surface that data to you faster, or control how often the Health database is updated. As of iOS 14, only heart rate data
may be transmitted every few of seconds while all other health data generated off the Apple Watch
may be transmitted up to 30 minutes later. So
continuous monitoring has a different definition in consumer-targeted health care devices such as the Apple Watch and this is not related to accuracy but only to data types supported, speed of generation, transmission, and storage.
Best of luck with your research project.