protected boolean checkCoverage(){
  int i;
  int n;
  int[] count;
  Range r;
  String attrIndex;
  SubspaceClusterDefinition cl;
  count=new int[getNumAttributes()];
  for (i=0; i < getNumAttributes(); i++) {
    for (n=0; n < getClusters().length; n++) {
      cl=(SubspaceClusterDefinition)getClusters()[n];
      r=new Range(cl.getAttrIndexRange());
      r.setUpper(getNumAttributes());
      if (r.isInRange(i)) {
        count[i]++;
      }
    }
  }
  attrIndex="";
  for (i=0; i < count.length; i++) {
    if (count[i] == 0) {
      if (attrIndex.length() != 0) {
        attrIndex+=",";
      }
      attrIndex+=(i + 1);
    }
  }
  if (attrIndex.length() != 0) {
    throw new IllegalArgumentException("The following attributes are not covered by a cluster " + "definition: " + attrIndex + "\n");
  }
  return true;
}

protected boolean checkCoverage ( ) { int i ; int n ; int [ ] count ; Range r ; String attrIndex ; SubspaceClusterDefinition cl ; count = new int [ getNumAttributes ( ) ] ; for ( i = 0 ; i < getNumAttributes ( ) ; i ++ ) { for ( n = 0 ; n < getClusters ( ) . length ; n ++ ) { cl = ( SubspaceClusterDefinition ) getClusters ( ) [ n ] ; r = new Range ( cl . getAttrIndexRange ( ) ) ; r . setUpper ( getNumAttributes ( ) ) ; if ( r . isInRange ( i ) ) { count [ i ] ++ ; } } } attrIndex = "" ; for ( i = 0 ; i < count . length ; i ++ ) { if ( count [ i ] == 0 ) { if ( attrIndex . length ( ) != 0 ) { attrIndex += "," ; } attrIndex += ( i + 1 ) ; } } if ( attrIndex . length ( ) != 0 ) { throw new IllegalArgumentException ( "The following attributes are not covered by a cluster " + "definition: " + attrIndex + "\n" ) ; } return true ; }
checks , whether all attributes are covered by cluster definitions and returns true in that case .
