label_categories
Relabel categories based on the top terms in each category.
This function enables the relabeling of category labels based on the most significant terms, or top_terms
, within
each category. It takes two columns as inputs: one with the old_labels
, which can be single or multi-valued categories,
and one with the top_terms
for each data point. The replacement of the labels is influenced by the specified rank method,
which can be TFIDF
, BACKGROUND
, FOREGROUND
, UPLIFT
, ORDINAL
, or ALPHANUM
, and the number of top terms considered
(specified by top_n
).
Was this page helpful?