4

2

From the SKOS spec.

Example 20 (consistent)

<MyConcept> skos:notation "303.4833"^^<MyNotationDatatype> .

New datatypes can be defined, and these are commonly called "user-defined datatypes".

What needs to be done to define ?

Is it something along the lines of

<MyNotationDatatype>
      a       rdfs:Datatype ;
      rdfs:label "Test"^^xsd:string ;
      rdfs:subClassOf rdfs:Resource .

Are there differences doing this in RDFS, OWL(2) Full, OWL-DL?

flag

1 Answer

2

OWL 2 has some powerful new features for defining datatypes. (When reading that document and all other OWL documents be sure to turn on the RDF examples first - you can do that somewhere after the table of contents.) For a SKOS notation you would probably do a regexp restriction on the datatype xsd:string. It would look like that:

<MyNotationDatatype>
   rdfs:label "XYZ notation"@en ;
   owl:equivalentClass [
      a rdfs:Datatype ;
      owl:onDatatype xsd:string ;
      owl:withRestrictions ([xsd:pattern "your regular expression goes here"])
   ] .

Using that in OWL 2 DL is no problem. If you want to stay within one of the profiles though note that defining datatypes through such restrictions isn't allowed in any of them. So for increased interoperability (also with OWL 1 and RDFS) you could just use xsd:string instead. That should be perfectly fine with SKOS.

link|flag
Thanks, how would that look in RDF/XML Syntax? (Will try to find out myself... but it's always helpful if someone can provide the correct version directly, and there are not too much material on this out on the web yet :( ) – Samuel Lampa Dec 7 at 14:26
I have now tried the following, but not sure if it is does what I expect (I expect it to define nmr:ppm as a double type, with no added restrictions): <?xml version="1.0" encoding="utf-8"?> <rdf:RDF xmlns:xsd="w3.org/2001/XMLSchema#"; xmlns:rdf="w3.org/1999/02/22-rdf-syntax-ns#"; xmlns:owl="w3.org/2002/07/owl#"; xmlns:nmr="ebi.ac.uk/nmrshiftdb/onto#"; > <rdf:Description rdf:about="nmr:ppm"> <rdf:type rdf:resource="rdfs:Datatype" /> <owl:onDataType rdf:resource="xsd:double" /> </rdf:Description> </rdf:RDF> – Samuel Lampa Dec 7 at 15:26

Your Answer

Get an OpenID
or

Not the answer you're looking for? Browse other questions tagged or ask your own question.