diff options
Diffstat (limited to 'sourcecodes/bnt-master/BNT/CPDs/@tabular_CPD/get_field.m')
| -rw-r--r-- | sourcecodes/bnt-master/BNT/CPDs/@tabular_CPD/get_field.m | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/sourcecodes/bnt-master/BNT/CPDs/@tabular_CPD/get_field.m b/sourcecodes/bnt-master/BNT/CPDs/@tabular_CPD/get_field.m new file mode 100644 index 00000000..ba233db9 --- /dev/null +++ b/sourcecodes/bnt-master/BNT/CPDs/@tabular_CPD/get_field.m @@ -0,0 +1,16 @@ +function val = get_field(CPD, name) +% GET_PARAMS Get the parameters (fields) for a tabular_CPD object +% val = get_params(CPD, name) +% +% The following fields can be accessed +% +% cpt, counts +% +% e.g., CPT = get_params(CPD, 'cpt') + +switch name + case 'cpt', val = CPD.CPT; + case 'counts', val = CPD.counts; + otherwise, + error(['invalid argument name ' name]); +end |
