Skip to content

Weird if statements in SimpleImputer.py #345

@eddiebergman

Description

@eddiebergman

I was browsing some code in SimpleImputer.py and I really have no idea how this multi-line double if statement with a 0 != 0 in it works? Little cleaning job I guess

if len(dataset_properties['numerical_columns']) \
        if isinstance(dataset_properties['numerical_columns'], List) else 0 != 0:
    add_hyperparameter(cs, numerical_strategy, CategoricalHyperparameter)

Metadata

Metadata

Assignees

No one assigned

    Labels

    refactoringImprovement of readability and abstract codes

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions