Research Article
SPONGY (SPam ONtoloGY): Email Classification Using Two-Level Dynamic Ontology
Algorithm 2
User-customized ontology filter pseudocode.
(1) // Initialize variables | (2) set training dataset d to | (3) set test dataset to | (4) set normalized values to | (5) | (6) Feature : ) ; | (7) Feature : ) UserProfileOntology(u); | (8) | (9) foreach : ) { | (10) foreach : ) { | (11) : ) Normalize ); | (12) } | (13) } | (14) foreach : ) { | (15) result C4.5 ); | (16) } | (17) | (18) Ontology () Jena(RdfConversion(result)); | (19) | (20) foreach(: ) { | (21) if(Ontology ) then | (22) decision = SPAM; | (23) else then | (24) decision = LEGITIMATE; | (25) } |
|