Skip to content

Commit

Permalink
Updates phenio.db association population to gene & disease phenotype …
Browse files Browse the repository at this point in the history
…associations
  • Loading branch information
kevinschaper committed Sep 12, 2024
1 parent 72a0ed2 commit 3d86eb2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/load_sqlite.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ pigz --force output/monarch-kg-denormalized-edges.tsv
echo "Populate phenio db term_association..."
cp data/monarch/phenio.db.gz output/phenio.db.gz
gunzip output/phenio.db.gz
sqlite3 -cmd "attach 'output/monarch-kg.db' as monarch" output/phenio.db "insert into term_association (id, subject, predicate, object, evidence_type, publication, source) select id, subject, predicate, object, has_evidence as evidence_type, publications as publication, primary_knowledge_source as source from monarch.edges where predicate = 'biolink:has_phenotype' and negated <> 'True'"
sqlite3 -cmd "attach 'output/monarch-kg.db' as monarch" output/phenio.db "insert into term_association (id, subject, predicate, object, evidence_type, publication, source) select id, subject, predicate, object, has_evidence as evidence_type, publications as publication, primary_knowledge_source as source from monarch.edges where category in ('biolink:GeneToPhenotypicFeatureAssociation','biolink:DiseaseToPhenotypicFeatureAssociation') and predicate = 'biolink:has_phenotype' and negated <> 'True' and has_count <> 0 and has_percentage <> 0"

echo "Compressing databases"
pigz --force output/phenio.db
Expand Down

0 comments on commit 3d86eb2

Please sign in to comment.