Structure of Strings
1 次查看(过去 30 天)
显示 更早的评论
Hi!
I want to specify possible parameters for the naive bayes classifier. For this reason, I have created a structure with a field for each parameter and a matrix with possible values.
bayesPosParams.distribution = ['normal'; 'kernel'];
bayesPosParams.prior = ['empirical'; 'uniform'];
bayesPosParams.KSWidth = 'scalar';
bayesPosParams.KSSupport = ['unbounded'; 'positive'];
Unfortunately that does not work: ??? Error using ==> vertcat CAT arguments dimensions are not consistent.
All Strings need to have the same length. What would be the best possibility to specify the parameters nice and consistently?
Thanks in advance, Jay
0 个评论
采纳的回答
Andrei Bobrov
2011-7-11
bayesPosParams.distribution = {'normal'; 'kernel'};
bayesPosParams.prior = {'empirical'; 'uniform'};
bayesPosParams.KSWidth = 'scalar';
bayesPosParams.KSSupport = {'unbounded'; 'positive'};
0 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 MATLAB Parallel Server 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!