aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMunyoki Kilyungi2026-01-28 23:32:18 +0300
committerMunyoki Kilyungi2026-01-28 23:32:37 +0300
commit4a0db655dadf07835362f5acea0ec0705120c9dc (patch)
tree80244f15c2d00c912fc291565ff4a81135436748
parent1097dfffa12cb0d0c18f5f4b2c91ecbaf6db2ded (diff)
downloadgn-transform-databases-4a0db655dadf07835362f5acea0ec0705120c9dc.tar.gz
Remodel genechip metadata.
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
-rwxr-xr-xexamples/dataset-metadata.scm3
-rwxr-xr-xexamples/gene-chip.scm44
2 files changed, 23 insertions, 24 deletions
diff --git a/examples/dataset-metadata.scm b/examples/dataset-metadata.scm
index 23dd48e..32dba7a 100755
--- a/examples/dataset-metadata.scm
+++ b/examples/dataset-metadata.scm
@@ -428,7 +428,8 @@
(list info-files
publishfreeze
genofreeze
- probesetfreeze))
+ probesetfreeze
+ gene-chip))
(outputs
`(#:documentation ,documentation
#:rdf ,output))))
diff --git a/examples/gene-chip.scm b/examples/gene-chip.scm
index a0de6b8..050c984 100755
--- a/examples/gene-chip.scm
+++ b/examples/gene-chip.scm
@@ -12,34 +12,38 @@
(transform special-forms))
-
-(define-transformer gene-chip
+(define-transformer gn:platform->metadata
(tables (GeneChip
(left-join Species "USING (SpeciesId)")))
(schema-triples
- (gnc:gene_chip a skos:Concept)
- (gnc:gene_chip
- skos:description
- "This is a set of controlled terms that are used to describe a given gene chip/platform")
- (gnt:has_geo_series_id rdfs:domain gnc:platform)
- (gnt:has_geo_series_id rdfs:domain gnc:gene_chip)
+ (gnc:gene_chip a skos:ConceptScheme)
+ (gnc:gene_chip skos:prefLabel "Gene Chip Vocabulary")
+ (gnc:gene_chip skos:definition "A controlled vocabulary used to describe gene chip and microarray platforms.")
+ (gnt:has_geo_series_id rdf:type owl:ObjectProperty)
+ (gnt:has_geo_series_id rdf:label "has GEO Series ID")
+ (gnt:has_geo_series_id rdfs:domain skos:Concept)
(gnt:has_go_tree_value a owl:ObjectProperty)
- (gnt:has_go_tree_value skos:definition "This resource the following GO tree value")
- (gnt:has_go_tree_value rdfs:domain gnc:gene_chip))
+ (gnt:has_go_tree_value rdfs:label "has GO tree value")
+ (gnt:has_go_tree_value
+ rdfs:comment
+ "Associates a gene chip concept with a Gene Ontology term used for categorization.")
+ (gnt:has_go_tree_value rdfs:domain skos:Concept)
+ (gnt:has_go_tree_value rdfs:range xsd:string))
(triples (string->identifier "platform" (field GeneChip Name) #:separator "_")
- (set rdf:type 'gnc:gene_chip)
- (set rdfs:label (field GeneChip GeneChipName))
+ (set rdf:type 'skos:Concept)
+ (set skos:inScheme (field GeneChip GeneChipName))
(set skos:prefLabel (field GeneChip Name))
(set skos:altLabel (field ("IF(GeneChip.GeneChipName != GeneChip.Title, Title, NULL)"
Title)))
(set gnt:has_go_tree_value (field GeneChip Go_tree_value))
- (set xkos:classifiedUnder
- (string->identifier "" (remap-species-identifiers (field Species Fullname)) #:separator ""))
+ (set gnt:has_species
+ (string->identifier "" (remap-species-identifiers (field Species Fullname))))
(set gnt:has_geo_series_id
(ontology 'geoSeries:
(string-trim-both (field GeneChip GeoPlatform))))))
+
(let* ((option-spec
'((settings (single-char #\s) (value #t))
(output (single-char #\o) (value #t))
@@ -52,25 +56,19 @@
(call-with-input-file settings
read)))
(with-documentation
- (name "Info files / Investigators Metadata")
+ (name "GeneChip Metadata")
(connection %connection-settings)
(table-metadata? #f)
(prefixes
- '(("v:" "<http://www.w3.org/2006/vcard/ns#>")
- ("foaf:" "<http://xmlns.com/foaf/0.1/#term_>")
- ("xsd:" "<http://www.w3.org/2001/XMLSchema#>")
- ("dcat:" "<http://www.w3.org/ns/dcat#>")
+ '(("xsd:" "<http://www.w3.org/2001/XMLSchema#>")
("skos:" "<http://www.w3.org/2004/02/skos/core#>")
- ("xkos:" "<http://rdf-vocabulary.ddialliance.org/xkos#>")
("geoSeries:" "<http://www.ncbi.nlm.nih.gov/geo/query/acc.cgi?acc=>")
("gnt:" "<http://rdf.genenetwork.org/v1/term/>")
("gn:" "<http://rdf.genenetwork.org/v1/id/>")
("gnc:" "<http://rdf.genenetwork.org/v1/category/>")
("rdf:" "<http://www.w3.org/1999/02/22-rdf-syntax-ns#>")
("owl:" "<http://www.w3.org/2002/07/owl#>")
- ("rdfs:" "<http://www.w3.org/2000/01/rdf-schema#>")
- ("taxon:" "<http://purl.uniprot.org/taxonomy/>")
- ("dct:" "<http://purl.org/dc/terms/>")))
+ ("rdfs:" "<http://www.w3.org/2000/01/rdf-schema#>")))
(inputs
(list gene-chip))
(outputs