public final ArrayList<Object>[] generateRules(double minConfidence,boolean noPrune){
  ArrayList<Object> premises=new ArrayList<Object>();
  ArrayList<Object> consequences=new ArrayList<Object>();
  ArrayList<Object> conf=new ArrayList<Object>();
  @SuppressWarnings("unchecked") ArrayList<Object>[] rules=new ArrayList[3];
  ItemSet premise, consequence;
  premise=new ItemSet(m_totalTransactions);
  consequence=new ItemSet(m_totalTransactions);
  int[] premiseItems=new int[m_items.length];
  int[] consequenceItems=new int[1];
  System.arraycopy(m_items,0,premiseItems,0,m_items.length);
  consequence.setItem(consequenceItems);
  premise.setItem(premiseItems);
  consequence.setItemAt(m_classLabel,0);
  consequence.setCounter(this.m_ruleSupCounter);
  premise.setCounter(this.m_counter);
  premises.add(premise);
  consequences.add(consequence);
  conf.add(new Double((double)this.m_ruleSupCounter / (double)this.m_counter));
  rules[0]=premises;
  rules[1]=consequences;
  rules[2]=conf;
  if (!noPrune) {
    pruneRules(rules,minConfidence);
  }
  return rules;
}

public final ArrayList < Object > [ ] generateRules ( double minConfidence , boolean noPrune ) { ArrayList < Object > premises = new ArrayList < Object > ( ) ; ArrayList < Object > consequences = new ArrayList < Object > ( ) ; ArrayList < Object > conf = new ArrayList < Object > ( ) ; @ SuppressWarnings ( "unchecked" ) ArrayList < Object > [ ] rules = new ArrayList [ 3 ] ; ItemSet premise , consequence ; premise = new ItemSet ( m_totalTransactions ) ; consequence = new ItemSet ( m_totalTransactions ) ; int [ ] premiseItems = new int [ m_items . length ] ; int [ ] consequenceItems = new int [ 1 ] ; System . arraycopy ( m_items , 0 , premiseItems , 0 , m_items . length ) ; consequence . setItem ( consequenceItems ) ; premise . setItem ( premiseItems ) ; consequence . setItemAt ( m_classLabel , 0 ) ; consequence . setCounter ( this . m_ruleSupCounter ) ; premise . setCounter ( this . m_counter ) ; premises . add ( premise ) ; consequences . add ( consequence ) ; conf . add ( new Double ( ( double ) this . m_ruleSupCounter / ( double ) this . m_counter ) ) ; rules [ 0 ] = premises ; rules [ 1 ] = consequences ; rules [ 2 ] = conf ; if ( ! noPrune ) { pruneRules ( rules , minConfidence ) ; } return rules ; }
generates rules out of item sets
