PDA

View Full Version : Check a dataset for one Instance



mthmulders
04-17-2007, 06:54 PM
Hello everybody,

does anyone know a way to check whether a dataset (an object of the Instances class) contains a certain Instance?

Regards,

Maarten

fracpete
06-22-2007, 02:24 AM
You can't. The ony thing that comes close, is sorting the Instance objects from the Instances object with java.util.Collections (method Collections.sort) and weka.core.InstanceComparator as comparator and then using Collections again for finding an Instance that is equal to another (method Collections.binarySearch).