for (Resource instance : instances) {
blackList.addAll(dataset.getStatementsFromStrings(instance.toString(), "http://swrc.ontoware.org/ontology#affiliation", null));
blackList.addAll(dataset.getStatementsFromStrings(null, "http://swrc.ontoware.org/ontology#employs", instance.toString()));
}
RDFIntersectionPartialSubTreeKernel kernel = new RDFIntersectionPartialSubTreeKernel();
double[][] matrix = kernel.compute(dataset, instances, blackList);
for (int i = 0; i < matrix.length; i++) {
System.out.println(Arrays.toString(matrix[i]));
}
}