Class: Google::Apis::HealthV4::DailyHeartRateVariability

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/health_v4/classes.rb,
lib/google/apis/health_v4/representations.rb,
lib/google/apis/health_v4/representations.rb

Overview

Represents the daily heart rate variability data type. At least one of the following fields must be set: - average_heart_rate_variability_milliseconds - non_rem_heart_rate_beats_per_minute - entropy - deep_sleep_root_mean_square_of_successive_differences_milliseconds

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ DailyHeartRateVariability

Returns a new instance of DailyHeartRateVariability.



600
601
602
# File 'lib/google/apis/health_v4/classes.rb', line 600

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#average_heart_rate_variability_millisecondsFloat

Optional. A user's average heart rate variability calculated using the root mean square of successive differences (RMSSD) in times between heartbeats. Corresponds to the JSON property averageHeartRateVariabilityMilliseconds

Returns:

  • (Float)


567
568
569
# File 'lib/google/apis/health_v4/classes.rb', line 567

def average_heart_rate_variability_milliseconds
  @average_heart_rate_variability_milliseconds
end

#dateGoogle::Apis::HealthV4::Date

Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type. TimeOfDay * google.type.DateTime * google.protobuf.Timestamp Corresponds to the JSON property date



579
580
581
# File 'lib/google/apis/health_v4/classes.rb', line 579

def date
  @date
end

#deep_sleep_root_mean_square_of_successive_differences_millisecondsFloat

Optional. The root mean square of successive differences (RMSSD) value during deep sleep. Corresponds to the JSON property deepSleepRootMeanSquareOfSuccessiveDifferencesMilliseconds

Returns:

  • (Float)


585
586
587
# File 'lib/google/apis/health_v4/classes.rb', line 585

def deep_sleep_root_mean_square_of_successive_differences_milliseconds
  @deep_sleep_root_mean_square_of_successive_differences_milliseconds
end

#entropyFloat

Optional. The Shanon entropy of heartbeat intervals. Entropy quantifies randomness or disorder in a system. High entropy indicates high HRV. Entropy is measured from the histogram of time interval between successive heart beats values measured during sleep. Corresponds to the JSON property entropy

Returns:

  • (Float)


593
594
595
# File 'lib/google/apis/health_v4/classes.rb', line 593

def entropy
  @entropy
end

#non_rem_heart_rate_beats_per_minuteFixnum

Optional. Non-REM heart rate Corresponds to the JSON property nonRemHeartRateBeatsPerMinute

Returns:

  • (Fixnum)


598
599
600
# File 'lib/google/apis/health_v4/classes.rb', line 598

def non_rem_heart_rate_beats_per_minute
  @non_rem_heart_rate_beats_per_minute
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



605
606
607
608
609
610
611
# File 'lib/google/apis/health_v4/classes.rb', line 605

def update!(**args)
  @average_heart_rate_variability_milliseconds = args[:average_heart_rate_variability_milliseconds] if args.key?(:average_heart_rate_variability_milliseconds)
  @date = args[:date] if args.key?(:date)
  @deep_sleep_root_mean_square_of_successive_differences_milliseconds = args[:deep_sleep_root_mean_square_of_successive_differences_milliseconds] if args.key?(:deep_sleep_root_mean_square_of_successive_differences_milliseconds)
  @entropy = args[:entropy] if args.key?(:entropy)
  @non_rem_heart_rate_beats_per_minute = args[:non_rem_heart_rate_beats_per_minute] if args.key?(:non_rem_heart_rate_beats_per_minute)
end