4 %> @brief Group Aggregator - Classes - Weighted Vote
6 %> @c X
property of output will have the ratio between the sum of weights
for for the assigned
class and total sum of weights in
9 %> Acts on
estimato datasets already processed by a
decider. The relevant thing is that the X
property must have the support
for the
14 o.classtitle = 'Weighted vote';
18 methods(Access=protected)
19 function o = process_group(o, idxs)
20 % Extracts from dataset for faster manipulation
21 classes = o.indata.classes(idxs);
22 X = o.indata.X(idxs, :);
24 poll = zeros(1, max(classes)+1); % Initializes poll
26 o.outdata.X(o.no_out, 1) = 0;
27 o.outdata.classes(o.no_out) = -1;
29 for i = 1:numel(classes)
31 poll(classes(i)+1) = poll(classes(i)+1)+X(i, 1);
34 [val, idx] = max(poll);
35 support = val/sum(poll);
36 o.outdata.X(o.no_out, 1) = support;
37 if support >= o.decisionthreshold
38 o.outdata.classes(o.no_out) = idx-1;
40 o.outdata.classes(o.no_out) = -1;
45 function o = dim_outdata(o, ng)
46 o.outdata.classes(ng, 1) = 0;
47 o.outdata.X(ng, 1) = 0;
Group Aggregator - Classes - Weighted Vote.
Block that resolves estimato posterior probabilities into classes.
Group Aggregator - classes.
Dataset representing estimation.