List of usage examples for weka.core.converters CSVLoader FILE_EXTENSION
String FILE_EXTENSION
To view the source code for weka.core.converters CSVLoader FILE_EXTENSION.
Click Source Link
From source file:adams.flow.transformer.WekaInstanceDumper.java
License:Open Source License
/** * Generates the filename for the output. * * @param header the current relation/*from ww w . ja v a2 s . co m*/ * @return the generated filename */ protected File createFilename(Instances header) { String result; File file; if (m_UseRelationNameAsFilename) { file = new File(m_OutputPrefix.getAbsolutePath()); result = file.getParent() + File.separator + FileUtils.createFilename(header.relationName(), "_"); } else { result = m_OutputPrefix.getAbsolutePath(); } if (m_Counter > 0) result += "-" + m_Counter; switch (m_OutputFormat) { case ARFF: result += ArffLoader.FILE_EXTENSION; break; case CSV: result += CSVLoader.FILE_EXTENSION; break; case TAB: result += CSVLoader.FILE_EXTENSION; break; default: throw new IllegalStateException("Unhandled output format: " + m_OutputFormat); } return new File(result); }