ontology

why this variable is never have a value

僤鯓⒐⒋嵵緔 提交于 2019-12-13 02:57:29
问题 I am checking that if an instance has a value for a specific predicate, bound that value to a specific variable, otherwise, bound that variable to the value 1 of type integer. this is my code select ?boosted where { :r1 a ?x optional { ?item rs:boostedBy ?boostedOptional bind (if(bound(?boostedOptional), ?boostedOptional, "1"^^xsd:integer) as ?boosted) } } the value of ?boosted is always empty, look please why please? Note I think you don't need data to test why my code is not working,

populate an existing ontology from a csv file using Jena

≡放荡痞女 提交于 2019-12-13 02:06:34
问题 How to read an ontology (owl file) using jena and populate this ontology (ontModel) from a CSV file then write the populated OntModel into OWL file 回答1: There are three parts to your question: reading an OWL file into a Jena Model converting a CSV file into RDF writing the contents of a Jena Model out to a file The first and third of these are easy with Jena (see Model.read() and Model.write() methods, and the FileManager for some additional convenience support for reading from different

extract information from xml file as RDF triples

喜欢而已 提交于 2019-12-12 21:52:20
问题 Could any one please recommend a tutorial or tell me how can I build a java program for extracting information from xml files and produce the out put as RDF triples using an existing ontology. an example would be really helpful. Thanks 回答1: There are ready-made tools that address this problem, such as XSPARQL. You can write an XSPARQL query that queries the XML and produces RDF triples as output. This example should be pretty close to what you're looking for. 回答2: Your problem is really two

Why filter doesn't work in this context?

孤人 提交于 2019-12-12 20:57:19
问题 This is the query and the result: As you see, I am filtering out the users that are bo:ania , so why do they still appear? However, if I remove the widecard and select just the users ?user , bo:ania doesn't appear I didn't provide a minimum data example because this is a question about how filter and wildcard work, not about a problem in extracting some data from a data set. However, if you need a minimum data, I'm more than happy to provide it. 回答1: ?specificUser is bound to bo:ania by your

Gene ontology (GO) analysis for a list of Genes (with ENTREZID) in R?

纵饮孤独 提交于 2019-12-12 17:05:00
问题 I am very new with the GO analysis and I am a bit confuse how to do it my list of genes. I have a list of genes (n=10): gene_list SYMBOL ENTREZID GENENAME 1 AFAP1 60312 actin filament associated protein 1 2 ANAPC11 51529 anaphase promoting complex subunit 11 3 ANAPC5 51433 anaphase promoting complex subunit 5 4 ATL2 64225 atlastin GTPase 2 5 AURKA 6790 aurora kinase A 6 CCNB2 9133 cyclin B2 7 CCND2 894 cyclin D2 8 CDCA2 157313 cell division cycle associated 2 9 CDCA7 83879 cell division cycle

Loading owl file with Jena

寵の児 提交于 2019-12-12 14:19:04
问题 I load several OWL files (RDF/XML serialization) with Jena as OntModel . For some files I get an error when reading them with ontoModel.read() : Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/HttpMessage . I have org.apache.httpcore-sources.jar in the classpath. The file which currently poses problem is: ontologydesignpatterns.org/cp/owl/timeindexedpersonrole.owl I saved it with Protege as RDF/XML, trying with both extensions .owl and .rdf . The code: public static

Measuring distances among classes in RDF/OWL graphs

时光怂恿深爱的人放手 提交于 2019-12-12 08:48:46
问题 Maybe someone could give me a hint. Is it possible to measure the distance between 2 concepts/classes that belong to the same ontology? For example, let's suppose I have an ontology with the Astronomy class and the Telescope class. There is a link between both, but it is not a direct link. Astronomy has a parent class called Science, and Telescope has a parent class called Optical Instrument which belongs to its parent called Instrumentation, that is related to a class called Empirical

The best tool for visualizing ontologies? [closed]

末鹿安然 提交于 2019-12-12 07:44:27
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 7 years ago . I am looking to visualize ontologies for understanding and making others understand. I would prefer to have top-down hierarchy of

How to write DL queries using java [closed]

拥有回忆 提交于 2019-12-12 05:29:49
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 5 years ago . How do I connect an ontology using java? I have created an ontology using protege. How can I write DL queries in Java to use this ontology? 回答1: You should take a look at the OWL API and Pellet. 回答2: DL queries are simply OWL class expressions. You can use the OWL-API as

URI of an RDF resource in Jena model

ぃ、小莉子 提交于 2019-12-12 05:25:22
问题 While I create resources in the model and print the URI, I get the correct namespace. For instance, the URI is http://www.somesite1.com/rdfdump/resources/resourceid-1 However, when I export the resources to an RDF file (link to the file) and I import it, I get the resource URI pointing to the physical location of the file in the disk such as file:///D:/somefolder/resources/resourceid-1 I am using com.hp.hpl.jena.rdf.model.Model in conjunction with com.hp.hpl.jena.ontology.OntModel . The RDF