perClass Documentation
version 5.2 (9-Jan-2018)
 SDCONFMAT Confusion matrix estimation and visualization


    SDCONFMAT(R)  % Interactive confmat from ROC object

    LAB      SDLAB object with true labels
    DEC      SDLAB object with classifier decisions
    R        SDROC object

    CM       Confusion matrix (double)

  'norm'   - normalize the confusion matrix
  'full'   - create a square confusion matrix using all possible classifier decisions
             (performances on diagonal).
  'classes',CLASSLL - use only classes in CLASSLL (SDLIST,string array or cellstr)
  'decisions',DECLL - use only decisions in DECLL (SDLIST,string array or cellstr)
  'string' - return string with confusion matrix (for report generation)
  'no header' - return string without header lines
  'replace',MAP - replace string content of confusion matrix. MAP is a cell array with
                  input and output rules (inputs can be regular expressions)
  'figure',F  - display confusion matrix in a figure (if F is given, use figure F)
   'row label',S - set string S as row label in figure (def:'True labels')
   'collumn label',S - set string S as a column label in figure (def:'Decisions')
   'fontsize',N - set fontsize in the figure (def:12);

 Specify rows and columns that appear even if one of the classes is missing:
   >> sdconfmat(a.lab,dec,'classes',{'apple','banana'},'decisions',{'apple','banana'})
 Show confusion matrix in a figure:
   >> sdconfmat(a.lab,dec,'figure')
 Replacing enpty fields in normalized matrix with dashes:
   >> sdconfmat(a.lab,a*pd,'norm','replace',{'0.000','  -  '})


sdconfmat is referenced in examples: