Package org.encog.app.analyst.script

Examples of org.encog.app.analyst.script.AnalystClassItem


    if( !this.isClassify() ) {
      throw new AnalystError("Can only calculate the mode for a class.");
    }
   
    DataField df = analyst.getScript().findDataField(this.name);
    AnalystClassItem m = null;
    int result = 0;
    int idx = 0;
    for( AnalystClassItem item: df.getClassMembers() )
    {
      if( m==null || m.getCount()<item.getCount() ) {
        m = item;
        result = idx;
      }
      idx++;
    }
View Full Code Here


        }
      }
    }

    if (isClass()) {
      AnalystClassItem item;

      // is this a new class?
      if (!this.classMap.containsKey(str)) {
        item = new AnalystClassItem(str, str, 1);
        this.classMap.put(str, item);

        // do we have too many different classes?
        final int max = this.script.getProperties().getPropertyInt(
            ScriptProperties.SETUP_CONFIG_MAX_CLASS_COUNT);
        if (this.classMap.size() > max) {
          setClass(false);
        }
      } else {
        item = this.classMap.get(str);
        item.increaseCount();
      }

    }
  }
View Full Code Here

        }
      }
    }

    if (isClass()) {
      AnalystClassItem item;

      // is this a new class?
      if (!this.classMap.containsKey(str)) {
        item = new AnalystClassItem(str, str, 1);
        this.classMap.put(str, item);

        // do we have too many different classes?
        final int max = this.script.getProperties().getPropertyInt(
            ScriptProperties.SETUP_CONFIG_MAX_CLASS_COUNT);
        if (this.classMap.size() > max) {
          setClass(false);
        }
      } else {
        item = this.classMap.get(str);
        item.increaseCount();
      }

    }
  }
View Full Code Here

    if( !this.isClassify() ) {
      throw new AnalystError("Can only calculate the mode for a class.");
    }
   
    DataField df = analyst.getScript().findDataField(this.name);
    AnalystClassItem m = null;
    int result = 0;
    int idx = 0;
    for( AnalystClassItem item: df.getClassMembers() )
    {
      if( m==null || m.getCount()<item.getCount() ) {
        m = item;
        result = idx;
      }
      idx++;
    }
View Full Code Here

TOP

Related Classes of org.encog.app.analyst.script.AnalystClassItem

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.