hpipy.utils.metrics.series_accuracy#

class hpipy.utils.metrics.series_accuracy(series_obj, test_method='insample', test_type='rt', pred_df=None, smooth=False, summarize=False, in_place=False, in_place_name='accuracy', **kwargs)[source]

Bases:

Calculate the accuracy for a series of indices.

Parameters:
  • series_obj (BaseHousePriceIndex) – Series object.

  • test_method (str, optional) – Testing method. Defaults to “insample”. Also supports “kfold” or “forecast”.

  • test_type (str, optional) – Testing type. Defaults to “rt”.

  • smooth (bool, optional) – Smooth the index. If True, the revision is calculated based on the smoothed indices. Defaults to False.

  • summarize (bool, optional) – Summarize the accuracy. Defaults to False.

  • in_place (bool, optional) – Return accuracy in-place. Defaults to False.

  • in_place_name (str, optional) – In-place attribute name. Defualts to “accuracy”.

  • pred_df (TransactionData | DataFrame | None)

  • kwargs (Any)

Returns:

Series object containing the

accuracy or DataFrame.

Return type:

BaseHousePriceIndex | pd.DataFrame

__call__(**kwargs)

Call self as a function.

__init__(**kwargs)