在命令行导出weka结果 [英] Export weka results on command line
问题描述
可以在通过命令行执行后导出weka结果?
我在做什么:
java -cp./weka.jarweka.classifiers.bayes.NaiveBayes -tiris.arff-i
pre>
但是,我有控制台中的所有统计信息,有没有办法导出这个?
解决方案p> Weka Primer 中的示例:
java -Xmx1024m weka.classifiers.trees.J48 -t data.arff -i -k -d J48-data.model>& ;! J48-data.out&
所以没有,WEKA在命令行没有特定的输出参数,使用
&!
或仅使用>
的错误输出到文件的输出和错误。 / p>
在您的情况下,您可以使用此命令将输出保存到文件
NaiveBayes-iris.out
:
java -cp./weka.jarweka.classifiers.bayes.NaiveBayes -tiris.arff-i> NaiveBayes-iris.out
Is it possible to export weka results after execute it via command line?
What I am doing:
java -cp "./weka.jar" weka.classifiers.bayes.NaiveBayes -t "iris.arff" -i
But then, I have all the statistics in console, is there any way to export this? Or I have to read and write by myself?
Thanks!
解决方案An example from the Weka Primer:
java -Xmx1024m weka.classifiers.trees.J48 -t data.arff -i -k -d J48-data.model >&! J48-data.out &
So no, WEKA doesn't have a specific output parameter on the command line, but you simply redirect the output and errors to a file using
>&!
or only the output without errors using>
.In your case you could use this command to save the output to the file
NaiveBayes-iris.out
:java -cp "./weka.jar" weka.classifiers.bayes.NaiveBayes -t "iris.arff" -i > NaiveBayes-iris.out
这篇关于在命令行导出weka结果的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!