-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Accessing statistics of support and confidence for rule classifiers defined in weka.classifiers.rules #29
Comments
Due to historic reasons, most classifiers implement their own, independent data structures. The RuleStats class is only used by JRip. Parsing the string representation of rules and then turning them back into Java data structures (from within Python using pww) seems an arduous process. |
@fracpete , thanks for the instant reply. Yes, I am able to get the ruleset for JRIP. For other methods, the rules are as a weka.classifier.Classifier object, so can you tell me which Weka classes should I use to get the ruleset from this classifier object. I need to provide the ruleset as a parameter to the RuleStats class for getting the statistics. |
These other classes do not provide an interface for accessing the rules, as far as I know (maybe there are |
Thanks a lot for your help. I will try to find out a way for this. BTW, the python-weka-wrapper3 is of great help to me. It saved the development time for me. |
Hey, I solved the issue by parsing the classifier outputs and creating methods for computing the statistics in Python. This is working fine. I agree to close this issue. |
Hey @fracpete ,
I am working on the rule generation methods OneR, PRISM, JRIP, PART, Decision list and others available in Weka using python-weka-wrapper. I want to get the basic statistics like coverage, confidence, true positive etc. of the generated rules. I got the rules as a string using toString() method on the Classifier object.
I was trying to use the RuleStats class defined in Weka for this but unable to figure out how to use it. So, can you help me with using RuleStat or suggest a way to get the ruleset for all the rule generation methods and the statistics for each rule?
Any help in this regard will be highly appreciated.
The text was updated successfully, but these errors were encountered: