Trying to predict equality between cell arrays
1 次查看(过去 30 天)
显示 更早的评论
I have two cell arrays A and B
A 400 x 1 cell
{1 x 5 categorical
1 x 5 categorical
1 x 5 categorical
.......}
B 400 x 1 cell
{1 x 5 categorical
1 x 5 categorical
1 x 5 categorical
.......}
I tried to do
C = sum(B == A)./numel(A)
And I am getting the following error
Undefined operator '==' for input arguments of type 'cell'.
Then I tried the following
C = sum(B{:} == A{:})./numel(A{:})
And I am getting the folowing error
Error using ==
Too many input arguments.
0 个评论
回答(1 个)
另请参阅
类别
在 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!