woodwork
woodwork copied to clipboard
ColumnSchema utils `is_numeric` and `is_categorical` only work if logical type is set
Currently the ColumnSchema utils is_numeric
and is_categorical
only look at the logical type when determining if a column schema is numeric or categorical in nature. In Featuretools, we often set just a "numeric"
or "category"
semantic tag in a column schema with no logical type in order to have the column schema be more general. Currently, those situations return False
when checking is_numeric
and is_categorical
respectively.
Ideally, Woodwork would recognize both of those as numeric and categorical as follows:
col_schema = ColumnSchema(semantic_tags={'numeric'})
assert col_schema.is_numeric
col_schema = ColumnSchema(semantic_tags={'category'})
assert col_schema.is_categorical