SARS-CoV-2-Queries

sequenceVariants.rq

Code examples: curl

SPARQL

SELECT ?variant ?variantLabel ?sequence ?sequenceLabel ?taxon ?taxonLabel WHERE {
  ?variant wdt:P3433 ?sequence .
  ?sequence wdt:P703 / wdt:P171* wd:Q82069695 .
  ?variant  wdt:P703 ?taxon .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}

run or edit

Output

variant sequence taxon
C3267T (edit) ORF1a polyprotein;ORF1ab polyprotein (edit) SARS-CoV-2 Alpha variant (edit)
N501Y mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Alpha variant (edit)
N501Y mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Beta variant (edit)
N501Y mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Gamma variant (edit)
N501Y mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Theta variant (edit)
C5388A (edit) ORF1a polyprotein;ORF1ab polyprotein (edit) SARS-CoV-2 Alpha variant (edit)
C27972T (edit) ORF8 protein (edit) SARS-CoV-2 Alpha variant (edit)
P681H mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Alpha variant (edit)
P681H mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Theta variant (edit)
P681H mutation (edit) surface glycoprotein (edit) SARS-CoV-2 Lineage B.1.1.318 (edit)
P681H mutation (edit) surface glycoprotein (edit) Lineage B.1.1.207 (edit)
HV 69-70 deletion (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
Y144 deletion (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
ORF8 ∆382 (edit) ORF8 protein (edit) SARS-CoV-2 (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Beta variant (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) Cluster 5 (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Gamma variant (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) Lineage B.1.427 (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Lineage B.1.429 (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Eta variant (edit)
D614G mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Lineage B.1.1.318 (edit)
T6954C (edit) ORF1a polyprotein;ORF1ab polyprotein (edit) SARS-CoV-2 Alpha variant (edit)
11288-11296 deletion (edit) ORF1a polyprotein;ORF1ab polyprotein (edit) SARS-CoV-2 Alpha variant (edit)
C23271A (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
C23709T (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
T24506G (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
G24914C (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
G28048T (edit) ORF8 protein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
A28111G (edit) ORF8 protein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
C28977T (edit) nucleocapsid protein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
D3L (edit) nucleocapsid protein [SARS-CoV-2] (edit) SARS-CoV-2 Alpha variant (edit)
K417N mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 (edit)
K417N mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 Beta variant (edit)
E484A mutation (edit) spike glycoprotein [SARS-CoV-2] (edit) SARS-CoV-2 (edit)

Code examples

curl

curl -s https://raw.githubusercontent.com/egonw/SARS-CoV-2-Queries/master/sparql/sequenceVariants.rq | sed 's+<lang/>+en+' > sequenceVariants.rq

curl -H "Accept: text/tab-separated-values" -G https://query.wikidata.org/bigdata/namespace/wdq/sparql --data-urlencode query@sequenceVariants.rq

This SPARQL query is available under CCZero.