Examples of numInstances()


Examples of weka.core.Instances.numInstances()

    }

    if (m_adjustForTrends) {
      int timeStampIndex = result.attribute(m_timeStampName).index();

      m_lastTimeValue = result.instance(result.numInstances() - 1).value(
          timeStampIndex);
      Instance last = result.instance(result.numInstances() - 1);
      Instance secondToLast = result.instance(result.numInstances() - 2);
      /*
       * m_deltaTime = last.value(timeStampIndex) -
View Full Code Here

Examples of weka.core.Instances.numInstances()

    if (m_adjustForTrends) {
      int timeStampIndex = result.attribute(m_timeStampName).index();

      m_lastTimeValue = result.instance(result.numInstances() - 1).value(
          timeStampIndex);
      Instance last = result.instance(result.numInstances() - 1);
      Instance secondToLast = result.instance(result.numInstances() - 2);
      /*
       * m_deltaTime = last.value(timeStampIndex) -
       * secondToLast.value(timeStampIndex);
       */
 
View Full Code Here

Examples of weka.core.Instances.numInstances()

      int timeStampIndex = result.attribute(m_timeStampName).index();

      m_lastTimeValue = result.instance(result.numInstances() - 1).value(
          timeStampIndex);
      Instance last = result.instance(result.numInstances() - 1);
      Instance secondToLast = result.instance(result.numInstances() - 2);
      /*
       * m_deltaTime = last.value(timeStampIndex) -
       * secondToLast.value(timeStampIndex);
       */

 
View Full Code Here

Examples of weka.core.Instances.numInstances()

        }
      }

      System.err.println("******** Discarding " + start
          + " instances from the start.");
      result = new Instances(result, start, result.numInstances() - start);
    }
    // System.err.println(result);
    return result;
  }

View Full Code Here

Examples of weka.core.Instances.numInstances()

      Instances trainMod = new Instances(m_trainingData);
      trainMod = weka.classifiers.timeseries.core.Utils.replaceMissing(
          trainMod, lagMaker.getFieldsToLag(), lagMaker.getTimeStampField(),
          false, lagMaker.getPeriodicity(), lagMaker.getSkipEntries());

      if (trainMod.numInstances() != m_trainingData.numInstances()) {
        m_trainingData = trainMod;
      }

      if (m_evaluateTestData) {
        m_missingTimeStampTestSetRows = new ArrayList<String>();
View Full Code Here

Examples of weka.core.Instances.numInstances()

            testMod, lagMaker.getFieldsToLag(), lagMaker.getTimeStampField(),
            false, lagMaker.getPeriodicity(), lagMaker.getSkipEntries(),
            m_missingTargetListTestSet, m_missingTimeStampListTestSet,
            m_missingTimeStampTestSetRows);

        if (testMod.numInstances() != m_testData.numInstances()) {
          m_testData = testMod;
        }
      }

    }
View Full Code Here

Examples of weka.core.Instances.numInstances()

          notifyBatchClassifierListeners(ce);         
        } else {
          // if headers do not match check to see if it's
          // just the class that is different and that
          // all class values are missing
          if (testSet.numInstances() > 0) {
            if (testSet.classIndex() == m_trainingSet.classIndex() &&
                testSet.attributeStats(testSet.classIndex()).missingCount ==
                testSet.numInstances()) {
              // now check the other attributes against the training
              // structure
View Full Code Here

Examples of weka.core.Instances.numInstances()

          // just the class that is different and that
          // all class values are missing
          if (testSet.numInstances() > 0) {
            if (testSet.classIndex() == m_trainingSet.classIndex() &&
                testSet.attributeStats(testSet.classIndex()).missingCount ==
                testSet.numInstances()) {
              // now check the other attributes against the training
              // structure
              boolean ok = true;
              for (int i = 0; i < testSet.numAttributes(); i++) {
                if (i != testSet.classIndex()) {
View Full Code Here

Examples of weka.core.Instances.numInstances()

          outBuff.append("Lagged and derived variable options:\n\t").
          append(lagOptions + "\n\n");
        }

        outBuff.append("Relation:     " + inst.relationName() + '\n');
        outBuff.append("Instances:    " + inst.numInstances() + '\n');
        outBuff.append("Attributes:   " + inst.numAttributes() + '\n');
        if (inst.numAttributes() < 100) {
          for (int i = 0; i < inst.numAttributes(); i++) {
            outBuff.append("              " + inst.attribute(i).name()
                + '\n');
View Full Code Here

Examples of weka.core.Instances.numInstances()

      /*
       * // don't push the first instance into the filters because this one //
       * has already been pushed in earlier.
       */
      for (int i = 0; i < missingReplaced.numInstances(); i++) {
        applyFilters(missingReplaced.instance(i), false, false);
      }
      m_missingBuffer = new Instances(m_primedInput, 0);
      // m_previousPrimeInstance = inst;
    } else if (!wasBuffered) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.