​
Hi Andy,
​
Jena 2.12.1
​
RDF-Turtle
@prefix :      <http://crux.bmi.stonybrookmedicine.edu/dev/> .
@prefix x:     <http://www.w3.org/2001/XMLSchema/> .
<urn:uuid:2e1891a8-6add-4f6e-856f-ff20edc6b310>
        :FSD1                        0.775643 ;
        :FSD2                        0.130934 ;
        :FSD3                        0.031545 ;
        :FSD4                        0.013257 ;
        :FSD5                        0.005997 ;
        :FSD6                        0.004298 ;
      :HematoxlyinKurtosis         "-NaN"^^x:double .
     
JSON-LD
{
"@graph" : [
{
    "@id" : "urn:uuid:2e1891a8-6add-4f6e-856f-ff20edc6b310",
    "FSD1" : "0.775643",
    "FSD2" : "0.130934",
    "FSD3" : "0.031545",
    "FSD4" : "0.013257",
    "FSD5" : "0.005997",
    "FSD6" : "0.004298"}],
   "@context" : {
    "FSD2" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD2";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    "FSD5" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD5";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    "FSD6" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD6";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    "FSD3" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD3";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    "FSD1" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD1";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    "FSD4" : {
      "@id" : "http://crux.bmi.stonybrookmedicine.edu/dev/FSD4";,
      "@type" : "http://www.w3.org/2001/XMLSchema#decimal";
    },
    ":HematoxlyinKurtosis" : {
      "@type" : "x:double",
      "@value" : "-NaN"
    },
    "" : "http://crux.bmi.stonybrookmedicine.edu/dev/";
  }
  }
​
​
   - Erich
On Fri, 14 Nov 2014 15:27:18 +0000
 Andy Seaborne <[email protected]> wrote:
On 14/11/14 14:26, Erich Bremer wrote:
Jena converts numbers out as strings when serializing out to JSON-LD. I'm assuming this has something to do with the 53-bit issues. Is there
a way to modify this behavior? - Erich


Complete, minimal example? Version? Because it does for me when it's possible. 53-bit isms being one one of the issues. Preserving datatype is another.

TTL:
<http://example/> <http://example/p> 123 .

JSON-LD:
{
  "@id" : "http://example/";,
  "http://example/p"; : 123,
  "@context" : {
    "p" : {
      "@id" : "http://example/p";,
"@type" : "http://www.w3.org/2001/XMLSchema#integer";
    }
  }
}


        Andy
​
​

Reply via email to