Tabnine Logo
weka.filters.unsupervised.instance
Code IndexAdd Tabnine to your IDE (free)

How to use weka.filters.unsupervised.instance

Best Java code snippets using weka.filters.unsupervised.instance (Showing top 20 results out of 315)

origin: stackoverflow.com

 Instances data;
RemoveWithValues filter = new RemoveWithValues();

String[] options = new String[4];
options[0] = "-C";   // attribute index
options[1] = "5";    // 5
options[2] = "-S";   // match if value is smaller than
options[3] = "10";   // 10
filter.setOptions(options);

filter.setInputFormat(data);
Instances newData = Filter.useFilter(data, filter);
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for running this filter.
  *
  * @param args     arguments for the filter: use -h for help
  */
 public static void main(String[] args) {
  runFilter(new RemoveDuplicates(), args);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new Randomize(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

public void testSampleSizePercentNoReplacement() {
 ((Resample) m_Filter).setSampleSizePercent(20);
 ((Resample) m_Filter).setNoReplacement(true);
 Instances result = useFilter();
 assertEquals(m_Instances.numAttributes(), result.numAttributes());
 assertEquals("Expecting output to be 20% of input",
        (int) (m_Instances.numInstances() * 20.0 / 100),  result.numInstances());
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates a default Resample */
public Filter getFilter() {
 Resample f = new Resample();
 f.setSampleSizePercent(50);
 return f;
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new Resample(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new ReservoirSample(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  *
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String [] argv) {
  runFilter(new SparseToNonSparse(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new NonSparseToSparse(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

/**
 * Creates a SubsetByExpression filter with the given expression.
 * 
 * @param expr    the expression to use
 * @return        the filter
 */
public Filter getFilter(String expr) {
 SubsetByExpression result = new SubsetByExpression();
 result.setExpression(expr);
 return result;
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates a default RemovePercentage */
public Filter getFilter() {
 RemovePercentage f = new RemovePercentage();
 return f;
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new RemoveFolds(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for testing this class.
  * 
  * @param argv should contain arguments to the filter: use -h for help
  */
 public static void main(String[] argv) {
  runFilter(new RemoveMisclassified(), argv);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

 /**
  * Main method for running this filter.
  * 
  * @param args arguments for the filter: use -h for help
  */
 public static void main(String[] args) {
  runFilter(new SubsetByExpression(), args);
 }
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates a default RemoveRange */
public Filter getFilter() {
 RemoveRange f = new RemoveRange();
 return f;
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates an example SparseToNonSparse */
public Filter getFilter() {
 SparseToNonSparse f = new SparseToNonSparse();
 return f;
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates a default ReservoirSample */
public Filter getFilter() {
 ReservoirSample r = new ReservoirSample();
 return r;
}
origin: nz.ac.waikato.cms.weka/weka-stable

/** Creates a default RemoveFolds */
public Filter getFilter() {
 RemoveFolds f = new RemoveFolds();
 return f;
}
origin: nz.ac.waikato.cms.weka/weka-stable

/**
 * Creates a default SubsetByExpression filter.
 * 
 * @return        the filter
 */
@Override
public Filter getFilter() {
 return new SubsetByExpression();
}
origin: nz.ac.waikato.cms.weka/normalize

/** Creates a default Normalize */
public Filter getFilter() {
 Normalize f = new Normalize();
 return f;
}
weka.filters.unsupervised.instance

Most used classes

  • RemovePercentage
    A filter that removes a given percentage of a dataset. Valid options are: -P Speci
  • Randomize
    Randomly shuffles the order of instances passed through it. The random number generator is reset wi
  • Resample
    Produces a random subsample of a dataset using either sampling with replacement or without replacem
  • NonSparseToSparse
    An instance filter that converts all incoming instances into sparse format.
  • RemoveRange
    A filter that removes a given range of instances of a dataset. Valid options are: -R
  • ReservoirSample,
  • SparseToNonSparse,
  • RemoveDuplicates,
  • RemoveFolds,
  • RemoveFrequentValues,
  • RemoveMisclassified,
  • SubsetByExpression,
  • NonSparseToSparseTest,
  • RandomizeTest,
  • RemoveDuplicatesTest,
  • RemoveFoldsTest,
  • RemoveFrequentValuesTest,
  • RemoveMisclassifiedTest,
  • RemovePercentageTest
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now