# `FadingTargetMean`

### *class* capymoa.regressor.FadingTargetMean[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/regressor/_fading_target_mean.py#L7)

Bases: [`MOARegressor`](capymoa.base.MOARegressor.md#capymoa.base.MOARegressor)

Fading Target Mean Regressor.

Maintains a fading mean of the target values to make predictions. The fading factor
determines the rate at which older observations are discounted. A fading factor close
to 1.0 gives more weight to older observations, while a factor closer to 0.0 emphasizes
more recent data.

#### SEE ALSO
[`NoChange()`](capymoa.regressor.NoChange.md#capymoa.regressor.NoChange)
[`TargetMean()`](capymoa.regressor.TargetMean.md#capymoa.regressor.TargetMean)

#### \_\_init_\_(schema: [Schema](capymoa.stream.Schema.md#capymoa.stream.Schema) | [None](https://docs.python.org/3/builtins/constants.html#None) = None, factor: [float](https://docs.python.org/3/builtins/functions.html#float) = 0.99)[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/regressor/_fading_target_mean.py#L21)

Construct Fading Target Mean Regressor.

* **Parameters:**
  * **schema** – Description of the stream’s data types.
  * **fading_factor** – The fading factor. Must be in (0, 1]. Defaults to 0.99.

#### cli_help()[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/base/_regressor.py#L53)

#### *classmethod* from_params(schema: [Any](https://docs.python.org/3/library/typing.html#typing.Any) = None, params: [dict](https://docs.python.org/3/builtins/stdtypes.html#dict)[[str](https://docs.python.org/3/builtins/stdtypes.html#str), [Any](https://docs.python.org/3/library/typing.html#typing.Any)] | [None](https://docs.python.org/3/builtins/constants.html#None) = None, random_seed: [int](https://docs.python.org/3/builtins/functions.html#int) = 1) → [Any](https://docs.python.org/3/library/typing.html#typing.Any)[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/base/_learner_params.py#L170)

Construct an instance from parameters produced by `get_params`.

#### get_params() → [dict](https://docs.python.org/3/builtins/stdtypes.html#dict)[[str](https://docs.python.org/3/builtins/stdtypes.html#str), [Any](https://docs.python.org/3/library/typing.html#typing.Any)][[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/base/_learner_params.py#L163)

Return the hyper-parameters captured from the constructor.

#### predict(instance)[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/base/_regressor.py#L59)

#### train(instance)[[source]](https://github.com/adaptive-machine-learning/CapyMOA/blob/3e255b1/src/capymoa/base/_regressor.py#L56)
