Class: Google::Apis::BigqueryV2::RegressionMetrics
- Inherits:
-
Object
- Object
- Google::Apis::BigqueryV2::RegressionMetrics
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/bigquery_v2/classes.rb,
lib/google/apis/bigquery_v2/representations.rb,
lib/google/apis/bigquery_v2/representations.rb
Overview
Evaluation metrics for regression and explicit feedback type matrix factorization models.
Instance Attribute Summary collapse
-
#mean_absolute_error ⇒ Float
Mean absolute error.
-
#mean_squared_error ⇒ Float
Mean squared error.
-
#mean_squared_log_error ⇒ Float
Mean squared log error.
-
#median_absolute_error ⇒ Float
Median absolute error.
-
#r_squared ⇒ Float
R^2 score.
Instance Method Summary collapse
-
#initialize(**args) ⇒ RegressionMetrics
constructor
A new instance of RegressionMetrics.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ RegressionMetrics
Returns a new instance of RegressionMetrics.
6415 6416 6417 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6415 def initialize(**args) update!(**args) end |
Instance Attribute Details
#mean_absolute_error ⇒ Float
Mean absolute error.
Corresponds to the JSON property meanAbsoluteError
6393 6394 6395 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6393 def mean_absolute_error @mean_absolute_error end |
#mean_squared_error ⇒ Float
Mean squared error.
Corresponds to the JSON property meanSquaredError
6398 6399 6400 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6398 def mean_squared_error @mean_squared_error end |
#mean_squared_log_error ⇒ Float
Mean squared log error.
Corresponds to the JSON property meanSquaredLogError
6403 6404 6405 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6403 def mean_squared_log_error @mean_squared_log_error end |
#median_absolute_error ⇒ Float
Median absolute error.
Corresponds to the JSON property medianAbsoluteError
6408 6409 6410 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6408 def median_absolute_error @median_absolute_error end |
#r_squared ⇒ Float
R^2 score. This corresponds to r2_score in ML.EVALUATE.
Corresponds to the JSON property rSquared
6413 6414 6415 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6413 def r_squared @r_squared end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
6420 6421 6422 6423 6424 6425 6426 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 6420 def update!(**args) @mean_absolute_error = args[:mean_absolute_error] if args.key?(:mean_absolute_error) @mean_squared_error = args[:mean_squared_error] if args.key?(:mean_squared_error) @mean_squared_log_error = args[:mean_squared_log_error] if args.key?(:mean_squared_log_error) @median_absolute_error = args[:median_absolute_error] if args.key?(:median_absolute_error) @r_squared = args[:r_squared] if args.key?(:r_squared) end |