@@ -0,0 +1,1934 @@
+import org.apache.jena.query.*;%0A%0Aimport java.io.IOException;%0Aimport java.util.List;%0Aimport java.util.stream.Collectors;%0A%0A/**%0A * Created by warreee on 12/16/15.%0A */%0Apublic class NobelPrize %7B%0A%0A    public static void main(String%5B%5D args) throws Exception %7B%0A        //nobelQuery(%22allNobelNames.rq%22, %22allNobelNames.csv%22);%0A        nobelQuery2(%22allNobelNames_notOnDBPedia.csv%22, %22almaMaterOfPerson_nobel.rq%22, %22almaMaterOfPersonNobel.csv%22, %22almaMaterOfPerson_notOnNobel.csv%22);%0A    %7D%0A%0A    // Get all names of nobel prize winners from nobelprize.org%0A    public static void nobelQuery(String queryFile, String resultFile) throws IOException %7B%0A        String queryString = Main.readFile(%22/Users/katrienlaenen/Documents/Eclipse/NobelprizeUniversities/%22 + queryFile);%0A        Query query = QueryFactory.create(queryString);%0A        QueryExecution qexec = QueryExecutionFactory.sparqlService(%22http://data.nobelprize.org/sparql%22, query);%0A%0A        try %7B%0A            ResultSet results = qexec.execSelect();%0A%0A%0A            for (; results.hasNext(); ) %7B%0A                QuerySolution solution = results.nextSolution();%0A                System.out.println(results.getResultVars());%0A%0A                List%3CString%3E res = results.getResultVars().stream().map(rv -%3E Main.getSolutionLiteral(solution, rv)).collect(Collectors.toList());%0A                Main.writeToCSV(res, true, resultFile);%0A                System.out.println(solution);%0A            %7D%0A%0A%0A        %7D finally %7B%0A            qexec.close();%0A        %7D%0A    %7D%0A    %0A    // Get all universities of nobel prize winners from nobelprize.org which were not found on dbpedia%0A    public static void nobelQuery2(String namesFile, String queryFile, String resultFile, String notFoundFile) throws IOException %7B%0A    %09Main.getUniversitiesOfPersons(%22allNobelNames_notOnDBPedia.csv%22, %22almaMaterOfPerson_nobel.rq%22, %22almaMaterOfPersonNobel.csv%22, %22allNobelNames_notOnNobel.csv%22, %22http://data.nobelprize.org/sparql%22);%0A    %7D%0A%0A%7D%0A

Create NobelPrize2.java