/** * Set the ResultProducer. * * @param newResultProducer new ResultProducer to use. */ public void setResultProducer(ResultProducer newResultProducer) { m_ResultProducer = newResultProducer; m_ResultProducer.setResultListener(this); findKeyIndex(); }
/** * When this method is called, it indicates that no more results will be sent * that need to be grouped together in any way. * * @param rp the ResultProducer that generated the results * @throws Exception if an error occurs */ @Override public void postProcess(ResultProducer rp) throws Exception { super.postProcess(rp); m_ResultListener.postProcess(this); }
/** * returns the ranking in a string representation. * * @return the ranking */ public String toStringRanking() { return new ResultMatrixPlainText(this).toStringRanking(); }
/** * Can be used after add/subtract/calculateDerived() */ private void checkStatsInitialized(Stats stats) { assertTrue("Incorrect initialization for count!", 0.0 == stats.count); assertTrue("Incorrect initialization for sum!", 0.0 == stats.sum); assertTrue("Incorrect initialization for sumSq!", 0.0 == stats.sumSq); assertNaN("Incorrect initialization for stdDev!", stats.stdDev); assertNaN("Incorrect initialization for mean!", stats.mean); assertNaN("Incorrect initialization for min!", stats.min); assertNaN("Incorrect initialization for max!", stats.max); }
/** * Makes a database query using the query set through the -Q option to convert * a table into a set of instances * * @return the instances contained in the result of the query * @throws Exception if an error occurs */ public Instances retrieveInstances() throws Exception { return retrieveInstances(m_Query); }
/** * When this method is called, it indicates that no more results will be sent * that need to be grouped together in any way. * * @param rp the ResultProducer that generated the results * @throws Exception if an error occurs */ @Override public void postProcess(ResultProducer rp) throws Exception { m_ResultListener.postProcess(this); }
/** * When this method is called, it indicates that no more requests to generate * results for the current experiment will be sent. The ResultProducer should * call preProcess(this) on the ResultListener it is to send results to. * * @throws Exception if an error occurs */ @Override public void postProcess() throws Exception { m_ResultProducer.postProcess(); }
/** * Checks whether cursors are scrollable in general, false otherwise (also if * not connected). * * @return true if scrollable and connected * @see #getSupportedCursorScrollType() */ public boolean isCursorScrollable() { return (getSupportedCursorScrollType() != -1); }
/** * removes the stored data but retains the dimensions of the matrix. */ public void clear() { super.clear(); LEFT_PARENTHESES = "["; RIGHT_PARENTHESES = "]"; }
/** * Set the upper run number for the experiment. * * @param newRunUpper the upper run number for the experiment. */ @Override public void setRunUpper(int newRunUpper) { super.setRunUpper(newRunUpper); m_baseExperiment.setRunUpper(newRunUpper); }
/** * Set the result producer used for the current experiment. * * @param newResultProducer result producer to use for the current experiment. */ @Override public void setResultProducer(ResultProducer newResultProducer) { super.setResultProducer(newResultProducer); m_baseExperiment.setResultProducer(newResultProducer); }
/** * Set the datasets to use in the experiment * * @param ds the list of datasets to use */ @Override public void setDatasets(DefaultListModel ds) { super.setDatasets(ds); m_baseExperiment.setDatasets(ds); }
/** * sets the name of the row (if the index is valid). * * @param index the index of the row * @param name the name of the row */ public void setRowName(int index, String name) { if ((index >= 0) && (index < getRowCount())) { m_RowNames[index] = name; } }
/** * pads the given string on the right until it reaches the given length, if * longer cuts it down. if length is 0 then nothing is done. * * @param s the string to pad * @param length the max. length of the string * @return the padded string */ protected String padString(String s, int length) { return padString(s, length, false); }
/** * Set the SplitEvaluator. * * @param newSplitEvaluator new SplitEvaluator to use. */ public void setSplitEvaluator(SplitEvaluator newSplitEvaluator) { m_SplitEvaluator = newSplitEvaluator; m_SplitEvaluator.setAdditionalMeasures(m_AdditionalMeasures); }
/** * Reads the properties from the specified file and sets up the database * drivers. * * @param propsFile the props file to load, ignored if null or pointing to a * directory * @throws Exception if an error occurs */ public DatabaseUtils(File propsFile) throws Exception { this(loadProperties(propsFile)); }
/** * Set the ResultProducer. * * @param newResultProducer new ResultProducer to use. */ public void setResultProducer(ResultProducer newResultProducer) { m_ResultProducer = newResultProducer; m_ResultProducer.setResultListener(this); findKeyIndex(); }
/** * When this method is called, it indicates that no more results will be sent * that need to be grouped together in any way. * * @param rp the ResultProducer that generated the results * @throws Exception if an error occurs */ @Override public void postProcess(ResultProducer rp) throws Exception { super.postProcess(rp); m_ResultListener.postProcess(this); }
/** * When this method is called, it indicates that no more results will be sent * that need to be grouped together in any way. * * @param rp the ResultProducer that generated the results * @throws Exception if an error occurs */ @Override public void postProcess(ResultProducer rp) throws Exception { m_ResultListener.postProcess(this); }