Skip to content

Commit

Permalink
Fixed R2 calculation
Browse files Browse the repository at this point in the history
  • Loading branch information
andreygetmanov committed Dec 19, 2022
1 parent edffc87 commit c0ed0d7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fedot/core/composer/metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ class R2(QualityMetric):
default_value = 0

@staticmethod
@from_maximised_metric
def metric(reference: InputData, predicted: OutputData) -> float:
return r2_score(y_true=reference.target, y_pred=predicted.predict)

Expand Down

0 comments on commit c0ed0d7

Please sign in to comment.