private int getSupport ( int [ ] itemset , int index , Node node ) { int item = order [ itemset [ index ] ] ; Node child = node . children [ item ] ; if ( child != null ) { // If the index is 0, then this is the last element (i.e the // input is a 1 itemset) and therefore item set found if ( index == 0 ) { return child . support ; } else { if ( child . children != null ) { return getSupport ( itemset , index - 1 , child ) ; } } } return 0 ; }
Returns the support value for the given item set if found in the T - tree and 0 otherwise .