A decision tree classifier is not working

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

A decision tree classifier is not working

anas2020
I faced the following error when using DT classifier
Exception in thread "main" net.sf.javaml.tools.weka.WekaException:
java.lang.IllegalArgumentException: Value not defined for given nominal
attribute!
        at
net.sf.javaml.tools.weka.WekaClassifier.classify(WekaClassifier.java:43)
        at psofc2.MyClassifier.classify(MyClassifier.java:98)
        at psofc2.TestingWithClassifier.fc(TestingWithClassifier.java:52)
        at psofc2.Main.main(Main.java:295)
Caused by: java.lang.IllegalArgumentException: Value not defined for given
nominal attribute!
        at weka.core.Instance.setValue(Unknown Source)
        at weka.core.Instance.setClassValue(Unknown Source)
        at
net.sf.javaml.tools.weka.ToWekaUtils.instanceToWeka(ToWekaUtils.java:87)
        at
net.sf.javaml.tools.weka.WekaClassifier.classify(WekaClassifier.java:41)
        ... 3 more
could someone help
Thanks



--
Sent from: https://weka.8497.n7.nabble.com/
_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html
Reply | Threaded
Open this post in threaded view
|

Re: A decision tree classifier is not working

Eibe Frank-2
Administrator

This does not look like a WEKA problem. The nominal value that the code attempts to set using setValue() is not part of the definition of the attribute. It seems that this must be a problem in the set-up of the WEKA attribute in JavaML. Try getting in touch with the people who provide help for that project.

 

Cheers,

Eibe

 

From: [hidden email]
Sent: Tuesday, 9 June 2020 6:30 PM
To: [hidden email]
Subject: [Wekalist] A decision tree classifier is not working

 

I faced the following error when using DT classifier

Exception in thread "main" net.sf.javaml.tools.weka.WekaException:

java.lang.IllegalArgumentException: Value not defined for given nominal

attribute!

        at

net.sf.javaml.tools.weka.WekaClassifier.classify(WekaClassifier.java:43)

        at psofc2.MyClassifier.classify(MyClassifier.java:98)

        at psofc2.TestingWithClassifier.fc(TestingWithClassifier.java:52)

        at psofc2.Main.main(Main.java:295)

Caused by: java.lang.IllegalArgumentException: Value not defined for given

nominal attribute!

        at weka.core.Instance.setValue(Unknown Source)

        at weka.core.Instance.setClassValue(Unknown Source)

        at

net.sf.javaml.tools.weka.ToWekaUtils.instanceToWeka(ToWekaUtils.java:87)

        at

net.sf.javaml.tools.weka.WekaClassifier.classify(WekaClassifier.java:41)

        ... 3 more

could someone help

Thanks

 

 

 

--

Sent from: https://weka.8497.n7.nabble.com/

_______________________________________________

Wekalist mailing list -- [hidden email]

Send posts to [hidden email]

To unsubscribe send an email to [hidden email]

To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz

List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html

 


_______________________________________________
Wekalist mailing list -- [hidden email]
Send posts to [hidden email]
To unsubscribe send an email to [hidden email]
To subscribe, unsubscribe, etc., visit https://list.waikato.ac.nz/postorius/lists/wekalist.list.waikato.ac.nz
List etiquette: http://www.cs.waikato.ac.nz/~ml/weka/mailinglist_etiquette.html