removecats
Remove categories from a categorical array.
Syntax
Section titled “Syntax”B = removecats(A)B = removecats(A, oldcats)Description
Section titled “Description”Returns A with the named oldcats categories removed. Data values that referenced those categories become <undefined> (see isundefined). With one argument, removes any categories that have no data values referencing them.
Examples
Section titled “Examples”C = categorical({'a', 'b', 'c'});removecats(C, 'c') % values now {'a', 'b', <undefined>}See also
Section titled “See also”addcats— Add categories to a categorical array.mergecats— Merge categories of a categorical array.isundefined— Test which categorical entries are undefined.