RE: [Classifier4j-devel] Next Step after Training?
Status: Beta
Brought to you by:
nicklothian
|
From: Nick L. <nl...@es...> - 2004-07-15 07:27:17
|
Yes, that looks fine.
The line "double result = classifier.classify(bayMsgs[i].getSubject());" is
doing the filtering.
Nick
-----Original Message-----
From: Kashif [mailto:ks...@ai...]
Sent: Thursday, 15 July 2004 3:54 PM
To: cla...@li...
Subject: [Classifier4j-devel] Next Step after Training?
Importance: Low
Hi
I solved the earlier problem with the "Exception in thread "main"
java.lang.NoClassDefFoundError:
org/apache/commons/logging/" I had to install the latest version of jdk.
Thanks Nick for your help with training the filter
I used the following code
// For Black List Arrays
for (int i=0; i<blackListArray.length; i++) {
classifier.teachNonMatch(blackListArray[i]);
}
// For White List Arrays
for (int i=0; i<whiteListArray.length; i++) {
classifier.teachMatch(whiteListArray[i]);
}
// For BayMsgs Arrays
// Applying Bayesian Filter on subject
// BayMsgs is an array of Message Object.
for (int i=0; i<bayMsgs.length; i++) {
double result =
classifier.classify(bayMsgs[i].getSubject());
}
Does this look OK to you.
Can you please let me know what are the next steps, and what should I do
next to apply Bayesian filter on the subject field only of bayMsgs Array,
which holds the Message Object.
Regards
And Thanks for our help.
|