class_docstr: This predictor selects between the target mean and the the user-selected regression model
   automatically. Faded error metrics are kept for both the predictors, and the most
  accurate one is selected automatically for each incoming instance.
class_docstr_tok: ["This","predictor","selects","between","the","target","mean","and","the","the","user-selected","regression","model","automatically",".","Faded","error","metrics","are","kept","for","both","the","predictors",",","and","the","most","accurate","one","is","selected","automatically","for","each","incoming","instance","."]
code: def __init__(
      self, model_predictor: base.Regressor, fading_factor: float
  ):
      self.model_predictor = model_predictor
      self.mean_predictor = MeanRegressor()
      self.fading_factor = fading_factor
  
      self._mae_mean = 0.0
      self._mae_model = 0.0
  
imports: from __future__ import annotations
  import collections
  import functools
  import io
  import math
  import typing
  from river import anomaly, base, drift, linear_model, stats
  from river.tree import split_criterion
  from river.tree import splitter
  from .base import HoeffdingRule
label_desc: Use image node_id 1 to create a new AdaptiveRegressor object from inherited base classes: base with example: obj = AdaptiveRegressor(model_predictor, fading_factor)