Package weka.core

Examples of weka.core.Range


  /**
   * Constructor
   */
  public MakeIndicator() {

      m_ValIndex = new Range("last");
  }
View Full Code Here


    boolean outputPredictionsText = m_OutputPredictionsTextBut.isSelected();
    if (m_OutputAdditionalAttributesText.getText().equals("")) {
      m_OutputAdditionalAttributesRange = null;
    }
    else {
      m_OutputAdditionalAttributesRange = new Range(m_OutputAdditionalAttributesText.getText());
      m_OutputAdditionalAttributesRange.setUpper(inst.numAttributes() - 1);
    }

    String grph = null;
View Full Code Here

    outputFormat.insertAttributeAt(newAttribute, m_Insert.getIndex());
    setOutputFormat(outputFormat);
   
    // all attributes, except index of added attribute
    // (otherwise the length of the input/output indices differ)
    Range atts = new Range(m_Insert.getSingleIndex());
    atts.setInvert(true);
    atts.setUpper(outputFormat.numAttributes() - 1);
    initOutputLocators(outputFormat, atts.getSelection());
   
    return true;
  }
View Full Code Here

    m_forwardSearchMethod = SEARCH_METHOD_FORWARD;
    m_performRanking = true;
    m_numUsedAttributes = 50;
    m_linearSelectionType = TYPE_FIXED_SET;
    m_starting = null;
    m_startRange = new Range();
    m_classIndex = -1;
    m_totalEvals = 0;
    m_cacheSize = 1;
    m_verbose = false;
  }
View Full Code Here

  }

  /** Default constructor */
  public RemoveWithValues() {

      m_Values = new Range("first-last");
      m_Values.setInvert(true);
  }
View Full Code Here

   * Constructor
   */
  public GreedyStepwise () {
    m_threshold = -Double.MAX_VALUE;
    m_doneRanking = false;
    m_startRange = new Range();
    m_starting = null;
    resetOptions();
  }
View Full Code Here

      setResultMatrix(new ResultMatrixHTML());
    if (Utils.getFlag("significance", options))
      setResultMatrix(new ResultMatrixSignificance());

    String datasetList = Utils.getOption('D', options);
    Range datasetRange = new Range();
    if (datasetList.length() != 0) {
      datasetRange.setRanges(datasetList);
    }
    setDatasetKeyColumns(datasetRange);

    String indexStr = Utils.getOption('R', options);
    if (indexStr.length() != 0) {
      if (indexStr.equals("first")) {
  setRunColumn(0);
      } else if (indexStr.equals("last")) {
  setRunColumn(-1);
      } else {
  setRunColumn(Integer.parseInt(indexStr) - 1);
      }   
    } else {
      setRunColumn(-1);
    }

    String foldStr = Utils.getOption('F', options);
    if (foldStr.length() != 0) {
      setFoldColumn(Integer.parseInt(foldStr) - 1);
    } else {
      setFoldColumn(-1);
    }

    String sigStr = Utils.getOption('S', options);
    if (sigStr.length() != 0) {
      setSignificanceLevel((new Double(sigStr)).doubleValue());
    } else {
      setSignificanceLevel(0.05);
    }
   
    String resultsetList = Utils.getOption('G', options);
    Range generatorRange = new Range();
    if (resultsetList.length() != 0) {
      generatorRange.setRanges(resultsetList);
    }
    setResultsetKeyColumns(generatorRange);
  }
View Full Code Here

    m_CompareCombo.setEnabled(true);
    m_SortCombo.setEnabled(true);
    if (ExperimenterDefaults.getSorting().length() != 0)
      setSelectedItem(m_SortCombo, ExperimenterDefaults.getSorting());

    Range generatorRange = new Range();
    if (selectedList.length() != 0) {
      try {
  generatorRange.setRanges(selectedList);
      } catch (Exception ex) {
  ex.printStackTrace();
  System.err.println(ex.getMessage());
      }
    }
    m_TTester.setResultsetKeyColumns(generatorRange);

    generatorRange = new Range();
    if (selectedListDataset.length() != 0) {
      try {
  generatorRange.setRanges(selectedListDataset);
      } catch (Exception ex) {
  ex.printStackTrace();
  System.err.println(ex.getMessage());
      }
    }
View Full Code Here

      int [] selected = m_ResultKeyList.getSelectedIndices();
      String selectedList = "";
      for (int i = 0; i < selected.length; i++) {
  selectedList += "," + (selected[i] + 1);
      }
      Range generatorRange = new Range();
      if (selectedList.length() != 0) {
  try {
    generatorRange.setRanges(selectedList);
  } catch (Exception ex) {
    ex.printStackTrace();
    System.err.println(ex.getMessage());
  }
      }
View Full Code Here

      int [] selected = m_DatasetKeyList.getSelectedIndices();
      String selectedList = "";
      for (int i = 0; i < selected.length; i++) {
  selectedList += "," + (selected[i] + 1);
      }
      Range generatorRange = new Range();
      if (selectedList.length() != 0) {
  try {
    generatorRange.setRanges(selectedList);
  } catch (Exception ex) {
    ex.printStackTrace();
    System.err.println(ex.getMessage());
  }
      }
View Full Code Here

TOP

Related Classes of weka.core.Range

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.