Daniel@0: function val = get_params(CPD, name) Daniel@0: % GET_PARAMS Get the parameters (fields) for a tabular_CPD object Daniel@0: % val = get_params(CPD, name) Daniel@0: % Daniel@0: % The following fields can be accessed Daniel@0: % Daniel@0: % cpt - the CPT Daniel@0: % Daniel@0: % e.g., CPT = get_params(CPD, 'cpt') Daniel@0: Daniel@0: switch name Daniel@0: case 'cpt', val = CPD.CPT; Daniel@0: case 'tree', val = CPD.tree; Daniel@0: otherwise, Daniel@0: error(['invalid argument name ' name]); Daniel@0: end