Analysis of the Compatibility Criterion - compat.m

Syntax:
[comp,Spca]=compat(results,q,inic)

 results Structure Results of the PPCA based segmentation
 q Scalar integer Number of principal components
 inic Scalar integer or structure Initial number of segments or 
 initial parameters from  Bottom-Up algorithm
 
 comp Matrix Compatibility matrix
 Spca Matrix Similarity measure of PPCA models

This function computes the compatibility matrix comp (ncluster × ncluster) and the matrix Spca (ncluster × ncluster), which contains the similarity measures between the PPCA models based on the index developed by Krzanowski. This function computes the compatibility and similarity measures between each pair of segments/clusters.