Class: Google::Apis::PlaydeveloperreportingV1beta1::GooglePlayDeveloperReportingV1beta1Anomaly

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

Overview

Represents an anomaly detected in a dataset. Our anomaly detection systems flag datapoints in a time series that fall outside of and expected range derived from historical data. Although those expected ranges have an upper and a lower bound, we only flag anomalies when the data has become unexpectedly worse, which usually corresponds to the case where the metric crosses the upper bound. Multiple contiguous datapoints in a timeline outside of the expected range will be grouped into a single anomaly. Therefore, an anomaly represents effectively a segment of a metric's timeline. The information stored in the timeline_spec, dimensions and metric can be used to fetch a full timeline with extended ragne for context. Required permissions: to access this resource, the calling user needs the View app information (read- only) permission for the app.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GooglePlayDeveloperReportingV1beta1Anomaly

Returns a new instance of GooglePlayDeveloperReportingV1beta1Anomaly.



77
78
79
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 77

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

Instance Attribute Details

#dimensionsArray<Google::Apis::PlaydeveloperreportingV1beta1::GooglePlayDeveloperReportingV1beta1DimensionValue>

Combination of dimensions in which the anomaly was detected. Corresponds to the JSON property dimensions



43
44
45
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 43

def dimensions
  @dimensions
end

#metricGoogle::Apis::PlaydeveloperreportingV1beta1::GooglePlayDeveloperReportingV1beta1MetricValue

Represents the value of a metric. Corresponds to the JSON property metric



48
49
50
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 48

def metric
  @metric
end

#metric_setString

Metric set resource where the anomaly was detected. Corresponds to the JSON property metricSet

Returns:

  • (String)


53
54
55
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 53

def metric_set
  @metric_set
end

#nameString

Identifier. Name of the anomaly. Format: apps/app/anomalies/anomaly Corresponds to the JSON property name

Returns:

  • (String)


58
59
60
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 58

def name
  @name
end

#timeline_specGoogle::Apis::PlaydeveloperreportingV1beta1::GooglePlayDeveloperReportingV1beta1TimelineSpec

Specification of the time-related aggregation parameters of a timeline. Timelines have an aggregation period (DAILY, HOURLY, etc) which defines how events are aggregated in metrics. The points in a timeline are defined by the starting DateTime of the aggregation period. The duration is implicit in the AggregationPeriod. Hourly aggregation periods, when supported by a metric set, are always specified in UTC to avoid ambiguities around daylight saving time transitions, where an hour is skipped when adopting DST, and repeated when abandoning DST. For example, the timestamp '2021-11-07 01:00:00 America/ Los_Angeles' is ambiguous since it can correspond to '2021-11-07 08:00:00 UTC' or '2021-11-07 09:00:00 UTC'. Daily aggregation periods require specifying a timezone which will determine the precise instants of the start and the end of the day. Not all metric sets support all timezones, so make sure to check which timezones are supported by the metric set you want to query. Corresponds to the JSON property timelineSpec



75
76
77
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 75

def timeline_spec
  @timeline_spec
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



82
83
84
85
86
87
88
# File 'lib/google/apis/playdeveloperreporting_v1beta1/classes.rb', line 82

def update!(**args)
  @dimensions = args[:dimensions] if args.key?(:dimensions)
  @metric = args[:metric] if args.key?(:metric)
  @metric_set = args[:metric_set] if args.key?(:metric_set)
  @name = args[:name] if args.key?(:name)
  @timeline_spec = args[:timeline_spec] if args.key?(:timeline_spec)
end