String yHome = YooreekaConfigurator.getHome();

NewsDataset trainingDS = new FileListNewsDataset("TrainingDS");
trainingDS.setDocumentDir(yHome+"/data/ch07/training");
trainingDS.init();

NewsDataset ds1 = new FileListNewsDataset("Cluster-Classify-DS");
ds1.setDocumentDir(yHome+"/data/ch07/all");
ds1.init();

NewsDataset ds2 = new FileListNewsDataset("Classify-Cluster-DS");
ds2.setDocumentDir(yHome+"/data/ch07/all");
ds2.init();

NewsProcessor newsProcessor = new NewsProcessor(trainingDS);
newsProcessor.trainClassifier();

newsProcessor.createClusters(ds1);
newsProcessor.classifyClusters(ds1);

NewsUI ui1 = new NewsUI(ds1);
NewsUI.createAndShowUI(ui1);

newsProcessor.classifyStories(ds2);
newsProcessor.createClustersWithinTopics(ds2);

NewsUI ui2 = new NewsUI(ds2);
NewsUI.createAndShowUI(ui2);




