Skip to content

docs: Add docstrings to metric modules missing documentation #74

Description

@Aman-Cool

Description

Several metric modules expose public functions without docstrings. This makes it difficult for new contributors to understand:

  • what the function computes
  • what parameters it expects
  • what structure the function returns

Adding clear docstrings would improve maintainability and make the codebase easier to navigate for contributors.


Affected modules

The following modules contain public functions without docstrings:

  • structured_data_metrics/completeness.py
  • structured_data_metrics/duplicity.py
  • structured_data_metrics/outliers.py
  • structured_data_metrics/statistical_rate.py
  • structured_data_metrics/representation_rate.py
  • structured_data_metrics/add_noise.py
  • structured_data_metrics/summary_statistics.py

Expected fix

Add docstrings to the public functions in these modules following the format described in contributing.rst.

Example format:

def my_metric(data: pd.DataFrame, ...) -> dict:
    """
    One-line summary.

    Parameters
    ----------
    data : pd.DataFrame
        The input dataset.
    ...

    Returns
    -------
    dict
        Description of the returned structure.
    """

Docstrings should clearly explain:

  • the purpose of the metric
  • expected input parameters
  • the structure of the returned result

Contribution scope

A contributor can choose one or multiple modules, as each module represents a self-contained task.


Skills needed

  • Reading Python code
  • Technical writing

No machine learning or AI expertise is required.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions