From 371ab107ecff75980c4a44ab2cc3b461d45532a7 Mon Sep 17 00:00:00 2001 From: Ming Ying Date: Thu, 10 Sep 2020 16:41:47 -0400 Subject: [PATCH] Added statistics Cypher query for ICDC --- queries/ICDC_stats.cypher | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 queries/ICDC_stats.cypher diff --git a/queries/ICDC_stats.cypher b/queries/ICDC_stats.cypher new file mode 100644 index 00000000..39a1027a --- /dev/null +++ b/queries/ICDC_stats.cypher @@ -0,0 +1,12 @@ +MATCH (s:study) +OPTIONAL MATCH (s)<-[*]-(c:case) +WITH s, COUNT(DISTINCT c) AS cases +OPTIONAL MATCH (s)<-[*]-(samp:sample) +WITH s, cases, COUNT(DISTINCT samp) AS samples +OPTIONAL MATCH (s)<-[*]-(f:file) +WITH DISTINCT f, s, cases, samples +RETURN s.clinical_study_designation AS study_code, + COUNT(f) AS files, + SUM(f.file_size) AS totoal_size, + cases, + samples