annotate toolboxes/FullBNT-1.0.7/bnt/CPDs/@hhmm2Q_CPD/maximize_params.m @ 0:e9a9cd732c1e tip

first hg version after svn
author wolffd
date Tue, 10 Feb 2015 15:05:51 +0000
parents
children
rev   line source
wolffd@0 1 function CPD = maximize_params(CPD, temp)
wolffd@0 2 % MAXIMIZE_PARAMS Set the params of a hhmmQ node to their ML/MAP values.
wolffd@0 3 % CPD = maximize_params(CPD, temperature)
wolffd@0 4
wolffd@0 5 if sum(CPD.start_counts(:)) > 0
wolffd@0 6 CPD.startprob = mk_stochastic(CPD.start_counts);
wolffd@0 7 end
wolffd@0 8 if sum(CPD.trans_counts(:)) > 0
wolffd@0 9 CPD.transprob = mk_stochastic(CPD.trans_counts);
wolffd@0 10 end