diff options
author | Munyoki Kilyungi | 2023-07-26 13:43:33 +0300 |
---|---|---|
committer | Munyoki Kilyungi | 2023-07-31 13:12:24 +0300 |
commit | c179a0fcf762804dcfe27fb23760ace35f19e016 (patch) | |
tree | d9cce170789460528f808df3be4b6a725399ad69 /examples/dump-dataset-metadata.scm | |
parent | 04c28dfe05dc3e2cadad75890a630b227be60900 (diff) | |
download | gn-transform-databases-c179a0fcf762804dcfe27fb23760ace35f19e016.tar.gz |
Replace "gn-term" with "gnt" prefix
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
Diffstat (limited to 'examples/dump-dataset-metadata.scm')
-rwxr-xr-x | examples/dump-dataset-metadata.scm | 138 |
1 files changed, 69 insertions, 69 deletions
diff --git a/examples/dump-dataset-metadata.scm b/examples/dump-dataset-metadata.scm index c51364a..33e72fe 100755 --- a/examples/dump-dataset-metadata.scm +++ b/examples/dump-dataset-metadata.scm @@ -52,11 +52,11 @@ (foaf:givenName rdfs:range rdfs:Literal) (foaf:familyName rdfs:range rdfs:Literal) (foaf:homepage rdfs:range rdfs:Literal) - (gn-term:address rdfs:range rdfs:Literal) - (gn-term:city rdfs:range rdfs:Literal) - (gn-term:state rdfs:range rdfs:Literal) - (gn-term:zipCode rdfs:range rdfs:Literal) - (gn-term:country rdfs:range rdfs:Literal)) + (gnt:address rdfs:range rdfs:Literal) + (gnt:city rdfs:range rdfs:Literal) + (gnt:state rdfs:range rdfs:Literal) + (gnt:zipCode rdfs:range rdfs:Literal) + (gnt:country rdfs:range rdfs:Literal)) (triples (investigator-attributes->id (field Investigators FirstName) (field Investigators LastName) (field Investigators Email)) @@ -70,11 +70,11 @@ (set foaf:familyName (field ("CAST(CONVERT(BINARY CONVERT(LastName USING latin1) USING utf8) AS VARCHAR(100))" LastName))) (set foaf:homepage (field Investigators Url)) - (set gn-term:address (field Investigators Address)) - (set gn-term:city (field Investigators City)) - (set gn-term:state (field Investigators State)) - (set gn-term:zipCode (field Investigators ZipCode)) - (set gn-term:country (field Investigators Country)))) + (set gnt:address (field Investigators Address)) + (set gnt:city (field Investigators City)) + (set gnt:state (field Investigators State)) + (set gnt:zipCode (field Investigators ZipCode)) + (set gnt:country (field Investigators Country)))) (define-dump dump-info-files (tables (InfoFiles @@ -92,38 +92,38 @@ (left-join GeneChip "USING (GeneChipId)")) "WHERE GN_AccesionId IS NOT NULL") (schema-triples - (gn-term:dataset rdfs:range rdfs:Literal) - (gn-term:datasetOfInvestigator rdfs:domain gn:dataset) - (gn-term:datasetOfOrganization rdfs:domain gn:dataset) - (gn-term:datasetOfInvestigator rdfs:range foaf:Person) - (gn-term:datasetOfInbredSet rdfs:domain gn:dataset) - (gn-term:datasetOfInbredSet rdfs:range gn:inbredSet) - (gn-term:datasetOfSpecies rdfs:domain gn:dataset) - (gn-term:datasetOfSpecies rdfs:range gn:inbredSet) - (gn-term:datasetOfTissue rdfs:domain gn:dataset) - (gn-term:datasetOfTissue rdfs:range gn:tissue) - (gn-term:normalization rdfs:domain gn:dataset) - (gn-term:normalization rdfs:range gn:avgMethod) - (gn-term:datasetOfPlatform rdfs:domain gn:dataset) - (gn-term:datasetOfPlatform rdfs:range gn:geneChip) - (gn-term:accessionId rdfs:range rdfs:Literal) - (gn-term:datasetStatusName rdfs:range rdfs:Literal) - (gn-term:summary rdfs:range rdfs:Literal) - (gn-term:aboutTissue rdfs:range rdfs:Literal) - (gn-term:geoSeries rdfs:range rdfs:Literal) - (gn-term:name rdfs:range rdfs:Literal) - (gn-term:title rdfs:range rdfs:Literal) - (gn-term:publicationTitle rdfs:range rdfs:Literal) - (gn-term:specifics rdfs:range rdfs:Literal) - (gn-term:datasetGroup rdfs:range rdfs:Literal) - (gn-term:aboutCases rdfs:range rdfs:Literal) - (gn-term:aboutPlatform rdfs:range rdfs:Literal) - (gn-term:aboutDataProcessing rdfs:range rdfs:Literal) - (gn-term:notes rdfs:range rdfs:Literal) - (gn-term:experimentDesign rdfs:range rdfs:Literal) - (gn-term:contributors rdfs:range rdfs:Literal) - (gn-term:citation rdfs:range rdfs:Literal) - (gn-term:acknowledgment rdfs:range rdfs:Literal)) + (gnt:dataset rdfs:range rdfs:Literal) + (gnt:datasetOfInvestigator rdfs:domain gn:dataset) + (gnt:datasetOfOrganization rdfs:domain gn:dataset) + (gnt:datasetOfInvestigator rdfs:range foaf:Person) + (gnt:datasetOfInbredSet rdfs:domain gn:dataset) + (gnt:datasetOfInbredSet rdfs:range gn:inbredSet) + (gnt:datasetOfSpecies rdfs:domain gn:dataset) + (gnt:datasetOfSpecies rdfs:range gn:inbredSet) + (gnt:datasetOfTissue rdfs:domain gn:dataset) + (gnt:datasetOfTissue rdfs:range gn:tissue) + (gnt:normalization rdfs:domain gn:dataset) + (gnt:normalization rdfs:range gn:avgMethod) + (gnt:datasetOfPlatform rdfs:domain gn:dataset) + (gnt:datasetOfPlatform rdfs:range gn:geneChip) + (gnt:accessionId rdfs:range rdfs:Literal) + (gnt:datasetStatusName rdfs:range rdfs:Literal) + (gnt:summary rdfs:range rdfs:Literal) + (gnt:aboutTissue rdfs:range rdfs:Literal) + (gnt:geoSeries rdfs:range rdfs:Literal) + (gnt:name rdfs:range rdfs:Literal) + (gnt:title rdfs:range rdfs:Literal) + (gnt:publicationTitle rdfs:range rdfs:Literal) + (gnt:specifics rdfs:range rdfs:Literal) + (gnt:datasetGroup rdfs:range rdfs:Literal) + (gnt:aboutCases rdfs:range rdfs:Literal) + (gnt:aboutPlatform rdfs:range rdfs:Literal) + (gnt:aboutDataProcessing rdfs:range rdfs:Literal) + (gnt:notes rdfs:range rdfs:Literal) + (gnt:experimentDesign rdfs:range rdfs:Literal) + (gnt:contributors rdfs:range rdfs:Literal) + (gnt:citation rdfs:range rdfs:Literal) + (gnt:acknowledgment rdfs:range rdfs:Literal)) (triples (string->identifier "" (regexp-substitute/global #f "[^A-Za-z0-9:]" (field InfoFiles InfoPageName) @@ -133,84 +133,84 @@ (set rdf:type (string->symbol (field ("IF(GenoFreeze.Id IS NOT NULL, 'gn:genotypeDataset', IF(PublishFreeze.Id IS NOT NULL, 'gn:phenotypeDataset', 'gn:dataset'))" rdfType)))) - (set gn-term:name (regexp-substitute/global + (set gnt:name (regexp-substitute/global #f "^[Nn]one$" (field InfoFiles InfoPageName) "")) - (set gn-term:fullName + (set gnt:fullName (field ("IFNULL(GenoFreeze.FullName, IFNULL(PublishFreeze.FullName, ''))" DatasetFullName))) (set dct:created (field ("IFNULL(GenoFreeze.CreateTime, IFNULL(PublishFreeze.CreateTime, IFNULL(ProbeSetFreeze.CreateTime, '')))" createTimeGenoFreeze))) - (set gn-term:datasetOfInvestigator + (set gnt:datasetOfInvestigator (investigator-attributes->id (field Investigators FirstName) (field Investigators LastName) (field Investigators Email))) - (set gn-term:datasetOfOrganization + (set gnt:datasetOfOrganization (field ("CAST(CONVERT(BINARY CONVERT(Organizations.OrganizationName USING latin1) USING utf8) AS VARCHAR(1500))" Organizations))) - (set gn-term:accessionId (format #f "GN~a" (field InfoFiles GN_AccesionId))) - (set gn-term:datasetStatusName (string-downcase + (set gnt:accessionId (format #f "GN~a" (field InfoFiles GN_AccesionId))) + (set gnt:datasetStatusName (string-downcase (field DatasetStatus DatasetStatusName))) - (set gn-term:datasetOfInbredSet + (set gnt:datasetOfInbredSet (string->identifier "inbredSet" (field InbredSet Name InbredSetName))) - (set gn-term:datasetOfTissue (string->identifier "tissue" + (set gnt:datasetOfTissue (string->identifier "tissue" (field Tissue Short_Name))) - (set gn-term:normalization + (set gnt:normalization (string->identifier "avgmethod" ;; If AvgMethodName is NULL, assume N/A. (if (string-blank? (field AvgMethod Name AvgMethodName)) "N/A" (field AvgMethod Name AvgMethodName)))) - (set gn-term:datasetOfPlatform + (set gnt:datasetOfPlatform (string->identifier "platform" (field GeneChip Name GeneChip))) - (set gn-term:summary + (set gnt:summary (sanitize-rdf-string (field Datasets Summary))) - (set gn-term:aboutTissue + (set gnt:aboutTissue (sanitize-rdf-string (field Datasets AboutTissue))) - (set gn-term:geoSeries + (set gnt:geoSeries (let ((s (string-match "GSE[0-9]*" (field ("IFNULL(Datasets.GeoSeries, '')" GeoSeries))))) (if s (ontology 'geoSeries: (match:substring s)) ""))) - (set gn-term:title + (set gnt:title (regexp-substitute/global #f "^[Nn]one$" (field InfoFiles InfoFileTitle) "")) - (set gn-term:publicationTitle + (set gnt:publicationTitle (regexp-substitute/global #f "^[Nn]one$" (field Datasets PublicationTitle) "")) - (set gn-term:specifics (sanitize-rdf-string (field InfoFiles Specifics))) - (set gn-term:datasetGroup (field Datasets DatasetName DatasetGroup)) - (set gn-term:aboutCases + (set gnt:specifics (sanitize-rdf-string (field InfoFiles Specifics))) + (set gnt:datasetGroup (field Datasets DatasetName DatasetGroup)) + (set gnt:aboutCases (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.AboutCases USING latin1) USING utf8) AS VARCHAR(10000))" AboutCases)))) - (set gn-term:aboutPlatform + (set gnt:aboutPlatform (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.AboutPlatform USING latin1) USING utf8) AS VARCHAR(1500))" AboutPlatform)))) - (set gn-term:aboutDataProcessing + (set gnt:aboutDataProcessing (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.AboutDataProcessing USING latin1) USING utf8) AS VARCHAR(1500))" AboutDataProcessing)))) - (set gn-term:notes + (set gnt:notes (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.Notes USING latin1) USING utf8) AS VARCHAR(1500))" GNNotes)))) - (set gn-term:experimentDesign + (set gnt:experimentDesign (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.ExperimentDesign USING latin1) USING utf8) AS VARCHAR(1500))" ExperimentDesign)))) - (set gn-term:contributors + (set gnt:contributors (sanitize-rdf-string (field ("CAST(CONVERT(BINARY CONVERT(Datasets.Contributors USING latin1) USING utf8) AS VARCHAR(1500))" Contributors)))) - (set gn-term:citation + (set gnt:citation (sanitize-rdf-string (regexp-substitute/global #f "^[Nn]one$" @@ -218,7 +218,7 @@ ("CAST(CONVERT(BINARY CONVERT(Datasets.Citation USING latin1) USING utf8) AS VARCHAR(1500))" Citation)) ""))) - (set gn-term:dataSourceAcknowledgment + (set gnt:dataSourceAcknowledgment (sanitize-rdf-string (string-trim-both (regexp-substitute/global @@ -226,7 +226,7 @@ (field ("CAST(CONVERT(BINARY CONVERT(InfoFiles.Data_Source_Acknowledge USING latin1) USING utf8) AS VARCHAR(1500))" Data_Source_Acknowledge)) "")))) - (set gn-term:acknowledgment (sanitize-rdf-string + (set gnt:acknowledgment (sanitize-rdf-string (field Datasets Acknowledgment))))) @@ -239,7 +239,7 @@ (prefixes '(("foaf:" "<http://xmlns.com/foaf/0.1/>") ("geoSeries:" "<http://www.ncbi.nlm.nih.gov/geo/query/acc.cgi?acc=>") - ("gn-term:" "<http://genenetwork.org/term/>") + ("gnt:" "<http://genenetwork.org/term/>") ("gn:" "<http://genenetwork.org/id/>") ("rdf:" "<http://www.w3.org/1999/02/22-rdf-syntax-ns#>") ("rdfs:" "<http://www.w3.org/2000/01/rdf-schema#>") |