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개)
Jay
2011년 7월 11일
댓글 수: 6
Andrei Bobrov
2011년 7월 12일
dis - cell array, and may be any operation with 'dis', as with cellarrays
참고 항목
카테고리
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!