Loading...

Data Type

The kind of value a variable holds: int, float, str, bool, list, dict, etc.

When to use: Converting features before training; avoiding silent dtype promotions.

Example: type(3) is int; type(3.0) is float; type("3") is str; type(True) is bool. int(True) + 1 == 2.

More Python for ML Glossary terms