Skip to content

Logical error in selecting the most frequent categorical features based on the most frequent nearest neighbours of the majority class. #494

@RaghuSpaceRajan

Description

@RaghuSpaceRajan

col_sel = rng.choice(col_max == col_max.max())

Doing a choice() on col_max == col_max.max() returns a True or False and not the index of the wanted column.
I replaced it with:
col_sel = rng.choice(np.where(col_max == col_max.max())[0])

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions