wolffd@0: function [engine, loglik] = enter_evidence(engine, evidence, varargin) wolffd@0: % ENTER_EVIDENCE Add the specified evidence to the network (var_elim) wolffd@0: % [engine, loglik] = enter_evidence(engine, evidence, ...) wolffd@0: % wolffd@0: % evidence{i} = [] if if X(i) is hidden, and otherwise contains its observed value (scalar or column vector) wolffd@0: wolffd@0: % we could pre-process the evidence here, to prevent repeated work, but we don't. wolffd@0: engine.evidence = evidence; wolffd@0: wolffd@0: if nargout == 2 wolffd@0: [m, loglik] = marginal_nodes(engine, [1]); wolffd@0: end