How to tell two categorical arrays with different categories names are the same
1 次查看(过去 30 天)
显示 更早的评论
Assume I have two categorical arrays as for example the following:
X=[1,1,2,3];
y=[3,3,1,2];
The two arrays have different classes names (categories) but in the classification task they have the same classes. How could I tell that the two arrays are the same (have the same categories)?
0 个评论
采纳的回答
Peter Perkins
2022-3-24
You don't have categorical arrays, you have numeric arrays. If you had categorical arrays, you'd just look at their categories.
0 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Categorical Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!